diff --git a/app/src/frontend/route.tsx b/app/src/frontend/route.tsx index 47db3003..62c38042 100644 --- a/app/src/frontend/route.tsx +++ b/app/src/frontend/route.tsx @@ -33,7 +33,12 @@ export const AuthRoute: React.FC = ({ component: Component, children {...rest} render={props => { if(isAuthenticated) { - const { from } = props.location.state ?? { from: '/my-account.html'}; + let state = props.location.state as any; + let from = '/my-account.html'; + if ('from' in state){ + from = state.from; + } + return ; } else { if(Component) {