summaryrefslogtreecommitdiffstats
path: root/webapp/root.jsx
diff options
context:
space:
mode:
authorJoram Wilander <jwawilander@gmail.com>2017-04-07 14:47:58 -0400
committerGeorge Goldberg <george@gberg.me>2017-04-07 19:47:58 +0100
commitde3995a1ce0a5607ab791d38e882b406e2bb3952 (patch)
treed6e241fbb7f6a8d7bfe6c1258f094891ba576041 /webapp/root.jsx
parent6e31e017ebc03017639e6ca16196ea02546131be (diff)
downloadchat-de3995a1ce0a5607ab791d38e882b406e2bb3952.tar.gz
chat-de3995a1ce0a5607ab791d38e882b406e2bb3952.tar.bz2
chat-de3995a1ce0a5607ab791d38e882b406e2bb3952.zip
Fix possible MFA enforcement redirect loop (#6030)
Diffstat (limited to 'webapp/root.jsx')
-rw-r--r--webapp/root.jsx2
1 files changed, 2 insertions, 0 deletions
diff --git a/webapp/root.jsx b/webapp/root.jsx
index 98c744477..e28cbfd75 100644
--- a/webapp/root.jsx
+++ b/webapp/root.jsx
@@ -60,6 +60,8 @@ function preRenderSetup(callwhendone) {
// Make sure the websockets close and reset version
$(window).on('beforeunload',
() => {
+ // Turn off to prevent getting stuck in a loop
+ $(window).off('beforeunload');
BrowserStore.setLastServerVersion('');
if (UserStore.getCurrentUser()) {
AsyncClient.viewChannel('', ChannelStore.getCurrentId() || '');