Merge branch 'main' into ue

This commit is contained in:
tresabhi committed 2025-03-04 22:45:27 -06:00
commit 5d81b7ff5a
13 files changed
+2482 -2481

No files matched your search

@@ -39,7 +39,11 @@ const locale = Astro.params.locale ?? DEFAULT_LOCALE;
window.location.pathname.startsWith(`/${locale}`),
);
if (!isAPI && bestLocale !== currentPathLocale) {
if (
!isAPI && // not an api, duh!
localStorage.getItem('preferred-locale') !== null && // no preference, so probably google's crawler
bestLocale !== currentPathLocale // we need to redirect
) {
window.location.pathname = isI18nPath
? window.location.pathname.replace(
`/${currentPathLocale}`,