From f69cdd3841786bf870ed2d62041122140d25a7b7 Mon Sep 17 00:00:00 2001 From: MHSanaei Date: Wed, 13 May 2026 12:41:55 +0200 Subject: [PATCH] fix(settings): POST /logout after credential change --- frontend/src/pages/settings/SecurityTab.vue | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/frontend/src/pages/settings/SecurityTab.vue b/frontend/src/pages/settings/SecurityTab.vue index d841c787..bb9a2f73 100644 --- a/frontend/src/pages/settings/SecurityTab.vue +++ b/frontend/src/pages/settings/SecurityTab.vue @@ -52,10 +52,9 @@ async function sendUpdateUser() { try { const msg = await HttpUtil.post('/panel/setting/updateUser', user); if (msg?.success) { - // Force re-login at the standard logout path; basePath is handled - // by the Go router so a relative redirect is correct here. - const basePath = window.X_UI_BASE_PATH || ''; - window.location.replace(`${basePath}logout`); + await HttpUtil.post('/logout'); + const basePath = window.X_UI_BASE_PATH || '/'; + window.location.replace(basePath); } } finally { updating.value = false;