From 4cee2cf128aa9e99cb5f78a6ec19090df6155812 Mon Sep 17 00:00:00 2001 From: kolaente Date: Sat, 21 Feb 2026 23:00:51 +0100 Subject: [PATCH] fix: reset throttle on logout so checkAuth clears auth state logout() calls checkAuth() to clear the authenticated flag and user info. But since checkAuth() likely ran within the last minute (on the navigation that triggered logout), the now-working throttle would return early, leaving authenticated=true in the store despite the token being removed. This could cause Login.vue to redirect back to home. Resetting lastUserInfoRefresh to null before checkAuth() ensures the logout flow always runs fully. --- frontend/src/stores/auth.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/frontend/src/stores/auth.ts b/frontend/src/stores/auth.ts index 6023eec99..d602e9f2a 100644 --- a/frontend/src/stores/auth.ts +++ b/frontend/src/stores/auth.ts @@ -452,6 +452,7 @@ export const useAuthStore = defineStore('auth', () => { removeToken() const loggedInVia = getLoggedInVia() window.localStorage.clear() // Clear all settings and history we might have saved in local storage. + lastUserInfoRefresh.value = null await router.push({name: 'user.login'}) await checkAuth()