mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 10:58:30 -05:00
Dynamic ws protocol (#11757)
This commit is contained in:
@@ -208,7 +208,7 @@ export class BrowserSocketFactory implements ISocketFactory {
|
||||
}
|
||||
|
||||
connect(host: string, port: number, query: string, callback: IConnectCallback): void {
|
||||
const socket = this._webSocketFactory.create(`ws://${host}:${port}/?${query}&skipWebSocketFrames=false`);
|
||||
const socket = this._webSocketFactory.create(`${location.protocol === 'https:' ? 'wss' : 'ws'}://${host}:${port}/?${query}&skipWebSocketFrames=false`); // {{SQL CARBON EDIT}} # dynamic websocket protocol
|
||||
const errorListener = socket.onError((err) => callback(err, undefined));
|
||||
socket.onOpen(() => {
|
||||
errorListener.dispose();
|
||||
|
||||
Reference in New Issue
Block a user