diff --git a/src/Routes.js b/src/Routes.js index 3565dd37..0fa7ca4f 100644 --- a/src/Routes.js +++ b/src/Routes.js @@ -54,12 +54,11 @@ class RouteComponentRenderer extends Component { render() { const { route, match, location, staticContext, flattenedRoutes } = this.props; - const { component: RouteComponent, preferLogin = false } = route; + const { component: RouteComponent, authPage = 'SignupPage' } = route; const canShow = this.canShowComponent(); if (!canShow) { staticContext.forbidden = true; } - const authPageName = preferLogin ? 'LoginPage' : 'SignupPage'; return canShow ? : ; } } diff --git a/src/routesConfiguration.js b/src/routesConfiguration.js index b675a90c..2dd3b39b 100644 --- a/src/routesConfiguration.js +++ b/src/routesConfiguration.js @@ -309,7 +309,7 @@ const routesConfiguration = [ { path: '/email_verification', auth: true, - preferLogin: true, + authPage: 'LoginPage', exact: true, name: 'EmailVerificationPage', component: props => ,