fix: redirect to login page after logout instead of workbench

Logout and session expiry previously redirected to "workbench" which
requires authentication, causing 401 errors and a frozen page state.
Now correctly redirects to "login" page immediately.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
2026-06-02 18:47:00 +08:00
parent 6b9953625e
commit fd71b2b18e
+2 -2
View File
@@ -357,7 +357,7 @@ function App() {
canvasAutoOpenedRecentRef.current = false;
setWorkspaceExpanded(false);
if (options?.resetView) {
handleSetView("workbench");
handleSetView("login");
}
}, [clearSessionState, setProjects, setProjectsLoaded, setUsage, clearTasks, setRuntimeNotifications, setServerNotifications, setCanvasWorkflow, setCurrentCanvasProjectId, setWorkspaceExpanded, handleSetView]);
@@ -492,7 +492,7 @@ function App() {
if (nextSession) {
setSession(nextSession);
} else {
clearAuthenticatedState();
clearAuthenticatedState({ resetView: true });
}
} finally {
checking = false;