Merge pull request #58 from MarcoDuiker/patch-1

Update main.js
static
Shengdun Hua 2019-04-18 19:12:26 +08:00 committed by GitHub
commit 9945d907a9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -210,7 +210,7 @@ jQuery(function($){
return;
}
var ws_url = window.location.href.replace('http', 'ws'),
var ws_url = window.location.href.split('?')[0].replace('http', 'ws'),
join = (ws_url[ws_url.length-1] === '/' ? '' : '/'),
url = ws_url + join + 'ws?id=' + msg.id,
sock = new window.WebSocket(url),