Added additional load in route

This commit is contained in:
Nate Kelley 2025-09-17 10:08:17 -06:00
parent 16b0c275e5
commit fbe88c7c96
No known key found for this signature in database
GPG Key ID: FD90372AB8D98B4F
1 changed files with 1 additions and 0 deletions

View File

@ -14,6 +14,7 @@ export const Route = createFileRoute('/app')({
context: ({ context }) => ({ ...context, getAppLayout }),
beforeLoad: async () => {
try {
console.log('app route beforeLoad', typeof window !== 'undefined', import.meta.env.SSR);
const supabaseSession = await getSupabaseSession();
const { isExpired, accessToken = '' } = supabaseSession;
if (isExpired || !accessToken) {