diff --git a/projects/app/src/components/Layout/auth.tsx b/projects/app/src/components/Layout/auth.tsx index eda9674a7..5d717d045 100644 --- a/projects/app/src/components/Layout/auth.tsx +++ b/projects/app/src/components/Layout/auth.tsx @@ -26,13 +26,14 @@ const Auth = ({ children }: { children: JSX.Element | React.ReactNode }) => { useQuery( [router.pathname], () => { - if (unAuthPage[router.pathname] === true || userInfo) { + if (unAuthPage[router.pathname] === true) { return null; } else { return initUserInfo(); } }, { + refetchInterval: 10 * 60 * 1000, onError(error) { console.log('error->', error); router.replace(