We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 06f14a5 commit 074fa1aCopy full SHA for 074fa1a
app/ui.js
@@ -1033,16 +1033,17 @@ const UI = {
1033
1034
let url;
1035
1036
- url = UI.getSetting('encrypt') ? 'wss' : 'ws';
+ url = new URL("https://" + host);
1037
1038
- url += '://' + host;
+ url.protocol = UI.getSetting('encrypt') ? 'wss:' : 'ws:';
1039
if (port) {
1040
- url += ':' + port;
+ url.port = port;
1041
}
1042
- url += '/' + path;
+ url.pathname = '/' + path;
1043
1044
try {
1045
- UI.rfb = new RFB(document.getElementById('noVNC_container'), url,
+ UI.rfb = new RFB(document.getElementById('noVNC_container'),
1046
+ url.href,
1047
{ shared: UI.getSetting('shared'),
1048
repeaterID: UI.getSetting('repeaterID'),
1049
credentials: { password: password } });
0 commit comments