mirror of
https://gitlab.com/comunic/nodejs-webrtcsignalexchangerserver
synced 2024-11-24 06:19:27 +00:00
Can close connection to signaling server
This commit is contained in:
parent
a98b7e5407
commit
b12a28c4d0
@ -128,6 +128,14 @@ class SignalExchangerClient {
|
|||||||
return this.socket.readyState == WebSocket.OPEN;
|
return this.socket.readyState == WebSocket.OPEN;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Close the connection to the server (if connected)
|
||||||
|
*/
|
||||||
|
close() {
|
||||||
|
if(this.isConnected())
|
||||||
|
this.socket.close();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Method called once the client is successfully
|
* Method called once the client is successfully
|
||||||
* connected to the client
|
* connected to the client
|
||||||
|
@ -128,6 +128,14 @@ class SignalExchangerClient {
|
|||||||
return this.socket.readyState == WebSocket.OPEN;
|
return this.socket.readyState == WebSocket.OPEN;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Close the connection to the server (if connected)
|
||||||
|
*/
|
||||||
|
close() {
|
||||||
|
if(this.isConnected())
|
||||||
|
this.socket.close();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Method called once the client is successfully
|
* Method called once the client is successfully
|
||||||
* connected to the client
|
* connected to the client
|
||||||
|
Loading…
Reference in New Issue
Block a user