summaryrefslogtreecommitdiffstats
path: root/web/react/stores
diff options
context:
space:
mode:
authorChristopher Speller <crspeller@gmail.com>2016-01-21 10:01:15 -0500
committerChristopher Speller <crspeller@gmail.com>2016-01-21 10:01:15 -0500
commitc7faefbedcf540e938ab79e498ca86fabc967c5b (patch)
tree731262af8f8ff916a3e0d9260864804c0aaf84af /web/react/stores
parent868eece9879131e9f2093a0e858533c9df76b55c (diff)
parentff8df5bf7d45ddd39df8b265ed6af07bd3932d55 (diff)
downloadchat-c7faefbedcf540e938ab79e498ca86fabc967c5b.tar.gz
chat-c7faefbedcf540e938ab79e498ca86fabc967c5b.tar.bz2
chat-c7faefbedcf540e938ab79e498ca86fabc967c5b.zip
Merge pull request #1924 from loafoe/master
[#1923] Make Websocket ports configurable
Diffstat (limited to 'web/react/stores')
-rw-r--r--web/react/stores/socket_store.jsx2
1 files changed, 1 insertions, 1 deletions
diff --git a/web/react/stores/socket_store.jsx b/web/react/stores/socket_store.jsx
index 24fa79ca6..f1fade305 100644
--- a/web/react/stores/socket_store.jsx
+++ b/web/react/stores/socket_store.jsx
@@ -49,7 +49,7 @@ class SocketStoreClass extends EventEmitter {
protocol = 'wss://';
}
- var connUrl = protocol + location.host + '/api/v1/websocket?' + Utils.getSessionIndex();
+ var connUrl = protocol + location.host + ((/:\d+/).test(location.host) ? '' : Utils.getWebsocketPort(protocol)) + '/api/v1/websocket?' + Utils.getSessionIndex();
if (this.failCount === 0) {
console.log('websocket connecting to ' + connUrl); //eslint-disable-line no-console