Update appimage

This commit is contained in:
MacRimi
2026-05-18 17:47:25 +02:00
parent c13601cd2d
commit 4bedeb9fcd
6 changed files with 52 additions and 25 deletions
+15
View File
@@ -26,6 +26,21 @@ export function Login({ onLogin }: LoginProps) {
const [loading, setLoading] = useState(false)
useEffect(() => {
// The Login screen is, by construction, the recovery path from any
// 401 cascade (the api-config wrapper redirects here when an
// expired/invalid JWT is detected). Clear the cascade-prevention
// flag on mount so a successful login can subsequently fire a fresh
// reload if a NEW 401 ever occurs. Without this clear, any 401 set
// earlier in the session sticks around forever and the next 401
// (e.g. mid-2FA, or right after a successful login if the token was
// briefly stale) is silently swallowed by the de-dup — the user
// sees a blank/stuck dashboard.
try {
sessionStorage.removeItem("proxmenux-auth-401-handled")
} catch {
// private browsing — best-effort
}
const savedUsername = localStorage.getItem("proxmenux-saved-username")
const savedPassword = localStorage.getItem("proxmenux-saved-password")