File tree Expand file tree Collapse file tree 2 files changed +2
-1
lines changed Expand file tree Collapse file tree 2 files changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -47,6 +47,7 @@ export const $te: typeof i18n.global.te = i18n.global.te;
4747// @ts -expect-error typing for i18n.global.locale is wrong when not in legacy mode;
4848// see https://vue-i18n.intlify.dev/guide/essentials/scope.html#local-scope-1
4949i18n . global . locale . value = 'enUS' ;
50+ await setI18nLocale ( ) ; // load and set initial (default) locale
5051
5152export function getLocaleProfile ( localeKey : string ) : LocaleProfile | undefined {
5253 return localeProfiles . find ( ( lp ) => lp . key === localeKey ) ;
Original file line number Diff line number Diff line change @@ -313,7 +313,7 @@ router.beforeEach(async (to, _from) => {
313313 if ( to . meta . restricted ) {
314314 const auth = useAuthStore ( ) ;
315315 const state = useStateStore ( ) ;
316- while ( ! state . init . authChecked ) await delay ( 50 ) ; // wait for session check
316+ while ( ! state . init . authChecked ) await delay ( 25 ) ; // wait for session check
317317 const ru = to . meta . restricted === 'user' ; // route is restricted to users
318318 const rsu = to . meta . restricted === 'superuser' ; // route is restricted to superusers
319319 const l = ! ! auth . user ; // a user is logged in
You can’t perform that action at this time.
0 commit comments