From 879049eea3358c1caed25e232430b06611d6da68 Mon Sep 17 00:00:00 2001 From: John Coffey Date: Thu, 19 Nov 2026 13:44:25 -0700 Subject: [PATCH] Back after switching accounts lands somewhere new (#128) Switching to a shared account pushed /mail, which opens the account now shown. The account isn't in the URL, so Back landed on the inbox already on screen and seemed to do nothing; each switch added one such step before Back closed the installed app. Replace on the switch, in a tab as in the installed app: the old entry could never bring the old account back. Reported on the forum (t/232, post 37). --- web/src/views/AppShell.tsx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/web/src/views/AppShell.tsx b/web/src/views/AppShell.tsx index b265097..9668dae 100644 --- a/web/src/views/AppShell.tsx +++ b/web/src/views/AppShell.tsx @@ -201,7 +201,11 @@ export function AppShell({ children }: { children: ReactNode }) { return; } useSession.getState().view(id); - navigate("/mail"); + // Replace, in a tab as in the installed app (#128): the account shown + // isn't in the URL, so a page left in the history can't bring the old + // account back -- Back would land on the inbox already showing and seem + // to do nothing. + navigate("/mail", { replace: true }); }; const composeOff = section !== "files" && section !== "calendar" && section !== "contacts" && composeBlocked() !== null; -- 2.54.0