summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--js/codeq/init.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/js/codeq/init.js b/js/codeq/init.js
index b7e903c..dfd9253 100644
--- a/js/codeq/init.js
+++ b/js/codeq/init.js
@@ -88,13 +88,14 @@
// we are a web app
$(window).on('load', Boot);
codeq.ajaxPrefix = location.pathname;
- codeq.eioHost= 'ws://' + location.host;
+ if (location.protocol == 'https:') codeq.eioHost= 'wss://' + location.host;
+ else codeq.eioHost= 'ws://' + location.host;
}
else {
// we are a phonegap native app
document.addEventListener("deviceready", Boot, false);
codeq.ajaxPrefix = 'http://codeq.si/';
- codeq.eioHost= 'ws://codeq.si';
+ codeq.eioHost= 'wss://codeq.si';
}
})();