From 2cb9042107bc6ef998a5b4c27e2a9559b06a1c1f Mon Sep 17 00:00:00 2001 From: Calvin Bui <3604363+calvinbui@users.noreply.github.com> Date: Sat, 13 May 2023 20:16:55 +1000 Subject: [PATCH] Update websocket.js to use browser scheme --- static/js/websocket.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/static/js/websocket.js b/static/js/websocket.js index 3cc1e81c..2f6dc009 100644 --- a/static/js/websocket.js +++ b/static/js/websocket.js @@ -14,7 +14,7 @@ var globals={ waitAnimation:undefined } -var socket = io.connect('http://' + document.domain + ':' + location.port); +var socket = io.connect(location.protocol + '//' + document.domain + ':' + location.port); socket.on('connect', function() { }); @@ -63,4 +63,4 @@ function send_message(service_name, parameters){ globals.socket.emit(service_name, parameters); globals.is_generating = true } -} \ No newline at end of file +}