From e7cba314d2846e8eb8960b84a0fed77e9ea066a7 Mon Sep 17 00:00:00 2001 From: Ashfame Date: Mon, 6 Mar 2023 22:56:58 +0400 Subject: [PATCH] don't even try to restore last url when in single room mode --- frontend/iframe/viewmodels/RootViewModel.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/frontend/iframe/viewmodels/RootViewModel.ts b/frontend/iframe/viewmodels/RootViewModel.ts index a48a121..624446c 100644 --- a/frontend/iframe/viewmodels/RootViewModel.ts +++ b/frontend/iframe/viewmodels/RootViewModel.ts @@ -79,7 +79,7 @@ export class RootViewModel extends ViewModel { } public get singleRoomMode(): boolean { - return !!this._resolvedSingleRoomId; + return !!this._singleRoomIdOrAlias; } public async start() { @@ -157,7 +157,8 @@ export class RootViewModel extends ViewModel { } } else { try { - if (!(shouldRestoreLastUrl && this.urlRouter.tryRestoreLastUrl())) { + // don't even try to restore last url when in single room mode + if (this.singleRoomMode || !(shouldRestoreLastUrl && this.urlRouter.tryRestoreLastUrl())) { const sessionInfos = await this.platform.sessionInfoStorage.getAll(); if (sessionInfos.length === 0) { this.navigation.push(Section.Login);