webrtc: do not connect if websocket unavailable.

This commit is contained in:
Miroslav Šedivý 2021-07-17 15:30:37 +02:00
parent 69f617ef45
commit 0974beaf4a

View File

@ -72,7 +72,9 @@ class WebrtcReconnecter extends ReconnecterAbstract {
} }
public async connect() { public async connect() {
this._websocket.send(EVENT.SIGNAL_REQUEST, { video: this._state.webrtc.video }) if (this._websocket.connected) {
this._websocket.send(EVENT.SIGNAL_REQUEST, { video: this._state.webrtc.video })
}
} }
public async disconnect() { public async disconnect() {