From 6eceaa562b5752ec884c15466241228db3955dc8 Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Mon, 17 Sep 2018 03:24:53 +0200 Subject: ughhhhhhhg --- app/client/auth/auth.gate.js | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) (limited to 'app/client/auth/auth.gate.js') diff --git a/app/client/auth/auth.gate.js b/app/client/auth/auth.gate.js index 087dfc6..07ab399 100644 --- a/app/client/auth/auth.gate.js +++ b/app/client/auth/auth.gate.js @@ -14,21 +14,15 @@ import { randint } from '../util/math' class AuthRouter extends Component { render(){ + console.log(this.props, Login) return (
- - - - - { - this.props.actions.setReturnTo(props.location.pathname) - return ( - - ) - }} /> + + +
@@ -41,11 +35,12 @@ class AuthRouter extends Component { class AuthGate extends Component { render(){ + console.log(this.props.auth) if (!this.props.auth.initialized) { return
Loading
} if (this.props.auth.isAuthenticated) return
{this.props.children}
- return + return } componentDidMount(){ this.props.actions.checkin() @@ -61,3 +56,11 @@ const mapDispatchToProps = (dispatch) => ({ }); export default connect(mapStateToProps, mapDispatchToProps)(AuthGate); + + // { + // console.log(window.location.pathname) + // this.props.actions.setReturnTo(window.location.pathname) + // return ( + // + // ) + // }} /> \ No newline at end of file -- cgit v1.2.3-70-g09d2