auto apply oxfmt rules

This commit is contained in:
2026-09-29 09:03:49 +02:00
parent 3fde18106d
commit 216dc70605
102 changed files with 36939 additions and 27387 deletions
+2 -11
View File
@@ -30,23 +30,14 @@ export const LocaleChecker = ({ children }: LocaleCheckerProps) => {
// If the user is authenticated and has a preferred locale that is different from the user's locale,
// then we update redirect to the user's preference
if (
status === "authenticated" &&
userLocale !== undefined &&
userLocale !== locale
) {
if (status === "authenticated" && userLocale !== undefined && userLocale !== locale) {
router.push({ pathname, params: params as any }, { locale: userLocale });
}
}, [locale, sessionData, status, params, pathname, router, userLocale]);
// To avoid flickering, we don't render the children until we have the user's locale
if (status === "loading") return null;
if (
status === "authenticated" &&
userLocale !== undefined &&
userLocale !== locale
)
return null;
if (status === "authenticated" && userLocale !== undefined && userLocale !== locale) return null;
return children;
};