diff options
| author | Mathias Biilmann Christensen <info@mathias-biilmann.net> | 2017-09-06 10:04:38 -0700 |
|---|---|---|
| committer | Mathias Biilmann Christensen <info@mathias-biilmann.net> | 2017-09-06 10:04:38 -0700 |
| commit | ab57ad3b7547089eee9a2fb4484c370ef6730c2a (patch) | |
| tree | ca089ddfa1a68daf0d79296ecfe4af77a53f6af2 | |
| parent | 2620084b200bbf18aa7d60d792f2c76f1f4a3759 (diff) | |
Fix issue with always redirecting to /admin when logged in
| -rw-r--r-- | src/js/app.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/js/app.js b/src/js/app.js index 0a7084a..31623bb 100644 --- a/src/js/app.js +++ b/src/js/app.js @@ -1,5 +1,5 @@ // JS Goes here - ES6 supported -if (window.netlifyIdentity) { +if (window.netlifyIdentity && !window.netlifyIdentity.currentUser()) { window.netlifyIdentity.on('login', () => { document.location.href = '/admin/'; }); |
