Merge pull request #6804 from matrix-org/t3chguy/fix/18481

This commit is contained in:
Michael Telatynski 2021-09-16 10:02:06 +01:00 committed by GitHub
commit 8921e25815
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -852,10 +852,11 @@ export class SpaceStoreClass extends AsyncStoreWithClient<IState> {
break; break;
case Action.SwitchSpace: case Action.SwitchSpace:
if (payload.num === 0) { // 1 is Home, 2-9 are the spaces after Home
if (payload.num === 1) {
this.setActiveSpace(null); this.setActiveSpace(null);
} else if (this.spacePanelSpaces.length >= payload.num) { } else if (this.spacePanelSpaces.length >= payload.num) {
this.setActiveSpace(this.spacePanelSpaces[payload.num - 1]); this.setActiveSpace(this.spacePanelSpaces[payload.num - 2]);
} }
break; break;