mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-05-04 23:14:12 +02:00
Frontend fixes (#22309)
* prevent unnecessary reloads in useUserPersistence hook * always render ProtectedRoute (handling undefined roles internally) and add Suspense fallback * add missing i18n namespaces react 19 enforces Suspense more strictly, so components using useTranslation() with unloaded namespaces would suspend, blanking the content behind the empty Suspense fallback * add missing namespace * remove unneeded * remove modal from actions dropdown
This commit is contained in:
@@ -116,6 +116,11 @@ export function useUserPersistence<S>(
|
||||
return;
|
||||
}
|
||||
|
||||
// Skip reload if we're already loaded for this key
|
||||
if (loadedKeyRef.current === namespacedKey) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Reset state when key changes - this prevents stale writes
|
||||
loadedKeyRef.current = null;
|
||||
migrationAttemptedRef.current = false;
|
||||
|
||||
Reference in New Issue
Block a user