Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Merge pull request #6730 from matrix-org/t3chguy/fix/17974
Browse files Browse the repository at this point in the history
Don't context switch room on SpaceStore ready as it can break permalinks
  • Loading branch information
t3chguy authored Sep 3, 2021
2 parents f7e491f + 44b4561 commit 0b07a70
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/stores/SpaceStore.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -782,7 +782,8 @@ export class SpaceStoreClass extends AsyncStoreWithClient<IState> {
// restore selected state from last session if any and still valid
const lastSpaceId = window.localStorage.getItem(ACTIVE_SPACE_LS_KEY);
if (lastSpaceId) {
this.setActiveSpace(this.matrixClient.getRoom(lastSpaceId));
// don't context switch here as it may break permalinks
this.setActiveSpace(this.matrixClient.getRoom(lastSpaceId), false);
}
}

Expand Down

0 comments on commit 0b07a70

Please sign in to comment.