fixed render bug
This commit is contained in:
@@ -103,6 +103,7 @@ export const Header = () => {
|
||||
Cookies.remove("token");
|
||||
setIsLoggedIn(false);
|
||||
setTriggerLogout(true);
|
||||
navigate("/login", { replace: true });
|
||||
};
|
||||
|
||||
return (
|
||||
|
||||
@@ -24,6 +24,7 @@ export const LoginPage = () => {
|
||||
useEffect(() => {
|
||||
if (isLoggedIn) {
|
||||
navigate("/", { replace: true });
|
||||
window.location.reload(); // Mit Tobais besprechen, ob das so bleiben soll
|
||||
}
|
||||
}, [isLoggedIn, navigate]);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user