From a7f237f9cfde64f1b4c0cf35e765aafd19d9c853 Mon Sep 17 00:00:00 2001 From: bhawesh96 Date: Wed, 31 Oct 2018 13:31:43 +0530 Subject: [PATCH] nav.jsx: Handle invalid token Signout the user and show the login-modal if the token is invalid https://github.com/coala/gh-board/issues/72 --- src/components/app/nav.jsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/components/app/nav.jsx b/src/components/app/nav.jsx index 4eb1d489..ce255331 100644 --- a/src/components/app/nav.jsx +++ b/src/components/app/nav.jsx @@ -63,7 +63,9 @@ class AppNav extends Component { // } this.setState({info}); }).catch(() => { - this.setState({info: null}); + alert("Invalid user token"); + this.onSignOut(); + this.setState({info: null, showModal: true}); }); };