Bladeren bron

fix(config) fix prejoin throwing a TypeError due to late config initialization (#10041)

master
Avram Tudor 3 jaren geleden
bovenliggende
commit
6b8db2ad9e
No account linked to committer's email address
2 gewijzigde bestanden met toevoegingen van 4 en 2 verwijderingen
  1. 2
    1
      react/features/toolbox/functions.native.js
  2. 2
    1
      react/features/toolbox/functions.web.js

+ 2
- 1
react/features/toolbox/functions.native.js Bestand weergeven

60
  */
60
  */
61
 export function isToolboxVisible(stateful: Object | Function) {
61
 export function isToolboxVisible(stateful: Object | Function) {
62
     const state = toState(stateful);
62
     const state = toState(stateful);
63
-    const { toolbarConfig: { alwaysVisible } } = state['features/base/config'];
63
+    const { toolbarConfig } = state['features/base/config'];
64
+    const { alwaysVisible } = toolbarConfig || {};
64
     const { enabled, visible } = state['features/toolbox'];
65
     const { enabled, visible } = state['features/toolbox'];
65
     const participantCount = getParticipantCountWithFake(state);
66
     const participantCount = getParticipantCountWithFake(state);
66
     const alwaysVisibleFlag = getFeatureFlag(state, TOOLBOX_ALWAYS_VISIBLE, false);
67
     const alwaysVisibleFlag = getFeatureFlag(state, TOOLBOX_ALWAYS_VISIBLE, false);

+ 2
- 1
react/features/toolbox/functions.web.js Bestand weergeven

39
  * otherwise.
39
  * otherwise.
40
  */
40
  */
41
 export function isToolboxVisible(state: Object) {
41
 export function isToolboxVisible(state: Object) {
42
-    const { iAmSipGateway, toolbarConfig: { alwaysVisible } } = state['features/base/config'];
42
+    const { iAmSipGateway, toolbarConfig } = state['features/base/config'];
43
+    const { alwaysVisible } = toolbarConfig || {};
43
     const {
44
     const {
44
         timeoutID,
45
         timeoutID,
45
         visible
46
         visible

Laden…
Annuleren
Opslaan