From b31ed66aafbe1d5dbe70d0cdfd70864204510d81 Mon Sep 17 00:00:00 2001 From: eug-vs Date: Tue, 30 Jun 2020 01:27:39 +0300 Subject: fix: re-implement navigation logic --- src/hooks/useAuth.tsx | 2 -- 1 file changed, 2 deletions(-) (limited to 'src/hooks/useAuth.tsx') diff --git a/src/hooks/useAuth.tsx b/src/hooks/useAuth.tsx index 00d0c7c..de64c46 100644 --- a/src/hooks/useAuth.tsx +++ b/src/hooks/useAuth.tsx @@ -33,7 +33,6 @@ const useProvideAuth = () => { const me = response.data.user; const token = response.data.accessToken; setUser(me); - // navigate('profile', me._id); localStorage.setItem('userId', me._id); localStorage.setItem('token', token); if (!remember) localStorage.setItem('shouldClear', 'true'); @@ -45,7 +44,6 @@ const useProvideAuth = () => { setUser(null); localStorage.removeItem('userId'); localStorage.removeItem('token'); - // navigate('auth'); }; const isAuthenticated = () => Boolean(user); -- cgit v1.2.3