This repository was archived by the owner on Sep 11, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -1072,13 +1072,19 @@ export class SpaceStoreClass extends AsyncStoreWithClient<IState> {
1072
1072
?. [ "m.room_versions" ] ?. [ "org.matrix.msc3244.room_capabilities" ] ?. [ "restricted" ] ;
1073
1073
} ) ;
1074
1074
1075
+ const oldMetaSpaces = this . _enabledMetaSpaces ;
1075
1076
const enabledMetaSpaces = SettingsStore . getValue ( "Spaces.enabledMetaSpaces" ) ;
1076
1077
this . _enabledMetaSpaces = metaSpaceOrder . filter ( k => enabledMetaSpaces [ k ] ) ;
1077
1078
1078
1079
this . _allRoomsInHome = SettingsStore . getValue ( "Spaces.allRoomsInHome" ) ;
1079
1080
this . sendUserProperties ( ) ;
1080
1081
1081
1082
this . rebuildSpaceHierarchy ( ) ; // trigger an initial update
1083
+ // rebuildSpaceHierarchy will only send an update if the spaces have changed.
1084
+ // If only the meta spaces have changed, we need to send an update ourselves.
1085
+ if ( arrayHasDiff ( oldMetaSpaces , this . _enabledMetaSpaces ) ) {
1086
+ this . emit ( UPDATE_TOP_LEVEL_SPACES , this . spacePanelSpaces , this . enabledMetaSpaces ) ;
1087
+ }
1082
1088
1083
1089
// restore selected state from last session if any and still valid
1084
1090
const lastSpaceId = window . localStorage . getItem ( ACTIVE_SPACE_LS_KEY ) ;
You can’t perform that action at this time.
0 commit comments