修正:HTTP方式访问,总览页面数据无法显示。

pull/105/head
Apex Liu 2018-03-26 18:05:23 +08:00
parent 61f8d6b3e6
commit 0847907d3c
1 changed files with 1 additions and 1 deletions

View File

@ -459,7 +459,7 @@ $app.init_ws = function () {
var _sid = Cookies.get('_sid');
console.log(location);
console.log(location.host);
if(location.protocol === 'http') {
if(location.protocol === 'http:') {
$app.ws = new WebSocket('ws://' + location.host + '/ws/' + _sid);
} else {
$app.ws = new WebSocket('wss://' + location.host + '/ws/' + _sid);