From c49a54786158bcc94953fa29f88cea61c82f7f73 Mon Sep 17 00:00:00 2001 From: Thomas Chazot Date: Fri, 15 Dec 2023 15:18:15 +0100 Subject: [PATCH] =?UTF-8?q?test=20pour=20=C3=AAtre=20connect=C3=A9=20direc?= =?UTF-8?q?t=20apr=C3=A8s=20login?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- cryptide_project/src/Contexts/AuthContext.tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cryptide_project/src/Contexts/AuthContext.tsx b/cryptide_project/src/Contexts/AuthContext.tsx index ac1b880..9adf7ef 100644 --- a/cryptide_project/src/Contexts/AuthContext.tsx +++ b/cryptide_project/src/Contexts/AuthContext.tsx @@ -23,6 +23,8 @@ const AuthProvider: React.FC<{ children: ReactNode }> = ({ children }) => { const [manager] = useState(new Manager(new DbUserService())) const login = async () => { + const [u, bool] = await manager.userService.fetchUserInformation() + setUser(u) setIsLoggedIn(true); };