From 0f7f55ec0a7e4f31a172ad2bd0fccef30c82f146 Mon Sep 17 00:00:00 2001 From: Marshall Polaris Date: Fri, 12 Aug 2022 20:14:10 -0700 Subject: [PATCH] Fix embarrassing bug in server auth --- web/lib/firebase/server-auth.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/web/lib/firebase/server-auth.ts b/web/lib/firebase/server-auth.ts index 8e5336c8..ebcb23d4 100644 --- a/web/lib/firebase/server-auth.ts +++ b/web/lib/firebase/server-auth.ts @@ -179,7 +179,7 @@ export const redirectIfLoggedIn =

( if (fn == null) { return { props: {} } } else { - const props = fn(ctx) + const props = await fn(ctx) console.debug('Finished getting initial props for rendering.') return props } @@ -203,7 +203,7 @@ export const redirectIfLoggedOut =

( if (fn == null) { return { props: {} } } else { - const props = fn(ctx, creds) + const props = await fn(ctx, creds) console.debug('Finished getting initial props for rendering.') return props }