fix(ui): preserve environment selection across logout
handleLogout explicitly cleared the env from localStorage, forcing the env switcher modal to re-open on every login. Drop that clear so the last selected env is restored from localStorage on the next session — the expected behavior for a personal-preference store. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -729,7 +729,6 @@ function LayoutContent() {
|
|||||||
// --- Callbacks ----------------------------------------------------
|
// --- Callbacks ----------------------------------------------------
|
||||||
const handleLogout = useCallback(() => {
|
const handleLogout = useCallback(() => {
|
||||||
logout();
|
logout();
|
||||||
useEnvironmentStore.getState().setEnvironment(undefined);
|
|
||||||
navigate('/login');
|
navigate('/login');
|
||||||
}, [logout, navigate]);
|
}, [logout, navigate]);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user