diff options
author | Corey Hulen <corey@hulen.com> | 2016-03-23 08:00:46 -0700 |
---|---|---|
committer | Corey Hulen <corey@hulen.com> | 2016-03-23 08:00:46 -0700 |
commit | aed690c5891a2cff97cc5fa00648c86be54ed8ee (patch) | |
tree | 542c2032409c614fb6b73bbfb03a5cdcbdaa9773 /webapp/root.jsx | |
parent | c7dbffec4dc11fe13b720ae0cd18afcb5b2f6bbd (diff) | |
parent | 9239a7353af2c67a6778ff4cabd164db62087bde (diff) | |
download | chat-aed690c5891a2cff97cc5fa00648c86be54ed8ee.tar.gz chat-aed690c5891a2cff97cc5fa00648c86be54ed8ee.tar.bz2 chat-aed690c5891a2cff97cc5fa00648c86be54ed8ee.zip |
Merge pull request #2512 from mattermost/plt-2473
PLT-2473, PLT-2310 Fixing websocket issues.
Diffstat (limited to 'webapp/root.jsx')
-rw-r--r-- | webapp/root.jsx | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/webapp/root.jsx b/webapp/root.jsx index b0a6ae1ac..b3041ad59 100644 --- a/webapp/root.jsx +++ b/webapp/root.jsx @@ -24,11 +24,11 @@ import Sidebar from 'components/sidebar.jsx'; import * as AsyncClient from 'utils/async_client.jsx'; import PreferenceStore from 'stores/preference_store.jsx'; import ChannelStore from 'stores/channel_store.jsx'; -import SocketStore from 'stores/socket_store.jsx'; import ErrorStore from 'stores/error_store.jsx'; import BrowserStore from 'stores/browser_store.jsx'; import SignupTeam from 'components/signup_team.jsx'; import * as Client from 'utils/client.jsx'; +import * as Websockets from 'action_creators/websocket_actions.jsx'; import * as GlobalActions from 'action_creators/global_actions.jsx'; import SignupTeamConfirm from 'components/signup_team_confirm.jsx'; import SignupUserComplete from 'components/signup_user_complete.jsx'; @@ -101,11 +101,10 @@ function preRenderSetup(callwhendone) { // Do Nothing }; + // Make sure the websockets close $(window).on('beforeunload', () => { - if (window.SocketStore) { - SocketStore.close(); - } + Websockets.close(); } ); |