Fix https detection
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
nemunaire 2022-03-01 18:32:43 +01:00
parent 1ed0b53b7c
commit ff0c75b3db
2 changed files with 2 additions and 2 deletions

View File

@ -87,7 +87,7 @@
function wsconnect() { function wsconnect() {
if (ws !== null) return; if (ws !== null) return;
ws = new WebSocket((window.location.protocol == 'https'?'wss://':'ws://') + window.location.host + `/api/surveys/${sid}/ws-admin`); ws = new WebSocket((window.location.protocol == 'https:'?'wss://':'ws://') + window.location.host + `/api/surveys/${sid}/ws-admin`);
ws.addEventListener("open", () => { ws.addEventListener("open", () => {
ws_up = true; ws_up = true;

View File

@ -64,7 +64,7 @@
} }
function wsconnect() { function wsconnect() {
const ws = new WebSocket((window.location.protocol == 'https'?'wss://':'ws://') + window.location.host + `/api/surveys/${sid}/ws`); const ws = new WebSocket((window.location.protocol == 'https:'?'wss://':'ws://') + window.location.host + `/api/surveys/${sid}/ws`);
ws.addEventListener("open", () => { ws.addEventListener("open", () => {
ws_up = true; ws_up = true;