mirror of
https://github.com/hyperspacedev/hyperspace
synced 2025-01-31 01:29:37 +01:00
Call userLoggedIn in PrivateRoute
This commit is contained in:
parent
073efe137b
commit
c94b483b47
@ -79,7 +79,7 @@ export const ProfileRoute = (rest: any, component: Component) => (
|
||||
export const PrivateRoute = (props: IPrivateRouteProps) => {
|
||||
const { component, render, ...rest } = props;
|
||||
const redir = (comp: any) =>
|
||||
userLoggedIn ? comp : <Redirect to="/welcome" />;
|
||||
userLoggedIn() ? comp : <Redirect to="/welcome" />;
|
||||
return (
|
||||
<Route
|
||||
{...rest}
|
||||
|
Loading…
x
Reference in New Issue
Block a user