From f01f28a7eac76c6da5bf857bfc80fd347586ce7f Mon Sep 17 00:00:00 2001 From: "HATEC\\SPVDEV001" Date: Wed, 16 Aug 2023 09:39:47 +0700 Subject: register google --- src/pages/_app.jsx | 10 +++++----- src/pages/my/menu.jsx | 9 +++++---- 2 files changed, 10 insertions(+), 9 deletions(-) (limited to 'src/pages') diff --git a/src/pages/_app.jsx b/src/pages/_app.jsx index 9f30752a..86cbe963 100644 --- a/src/pages/_app.jsx +++ b/src/pages/_app.jsx @@ -25,9 +25,9 @@ function MyApp({ Component, pageProps: { session, ...pageProps } }) { const [authenticated, setAuthenticated] = useState(null) const auth = getAuth() - useEffect(() => { - setAuthenticated(auth) - }, [auth]) + // useEffect(() => { + // setAuthenticated(auth) + // }, [auth]) useEffect(() => { const handleRouteChangeStart = () => setAnimateLoader(true) @@ -60,7 +60,7 @@ function MyApp({ Component, pageProps: { session, ...pageProps } }) { }, [isMobile]) return ( - + // {animateLoader && ( @@ -96,7 +96,7 @@ function MyApp({ Component, pageProps: { session, ...pageProps } }) { - + // ) } diff --git a/src/pages/my/menu.jsx b/src/pages/my/menu.jsx index bd20e2eb..fb8e6b03 100644 --- a/src/pages/my/menu.jsx +++ b/src/pages/my/menu.jsx @@ -11,11 +11,12 @@ import { useRouter } from 'next/router' export default function Menu() { const auth = useAuth() const router = useRouter() - const {data : session} = useSession() + const { data: session } = useSession() const logout = () => { - deleteAuth() - router.push('/login') + deleteAuth().then(() => { + router.push('/login') + }) } return ( @@ -64,7 +65,7 @@ export default function Menu() { Daftar Alamat -
(logout, signOut)} className='p-4 mt-2'> +
logout()} className='p-4 mt-2'>
-- cgit v1.2.3