Skip to content

Commit

Permalink
Only restore last url if there is already a session
Browse files Browse the repository at this point in the history
  • Loading branch information
psrpinto committed Nov 30, 2023
1 parent 1324eb4 commit 5a9b5d2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion frontend/iframe/viewmodels/RootViewModel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,9 @@ export class RootViewModel extends ViewModel<SegmentType, Options> {
}
}

let shouldRestoreLastUrl = true;
// Only restore last url if there is already a session.
// This will result in the user being sent to login screen.
let shouldRestoreLastUrl = sessionInfos.length > 1;

// We never want to show the session picker, even if it was the last url.
const willShowSessionPicker = this.platform.history.getLastSessionUrl() === "#/session";
Expand Down

0 comments on commit 5a9b5d2

Please sign in to comment.