Browse Source

Merge pull request #11175 from growilabs/fix/app-getinitialprops-await

fix(app): await App.getInitialProps in _app to fix SSR crash
Yuki Takei 4 days ago
parent
commit
819b41086c
1 changed files with 1 additions and 1 deletions
  1. 1 1
      apps/app/src/pages/_app.page.tsx

+ 1 - 1
apps/app/src/pages/_app.page.tsx

@@ -112,7 +112,7 @@ function GrowiApp(props: GrowiAppProps): JSX.Element {
 
 // inject userLocale by context
 GrowiApp.getInitialProps = async (appContext: AppContext) => {
-  const appProps = App.getInitialProps(appContext);
+  const appProps = await App.getInitialProps(appContext);
   const userLocale = getLocaleAtServerSide(
     appContext.ctx.req as unknown as CrowiRequest,
   );