mirror of
https://github.com/ragestudio/comty.js.git
synced 2025-06-08 18:14:18 +00:00
improve socket disconection to suport rtengineng
This commit is contained in:
parent
1838d32fe0
commit
3a2c3aeef0
@ -98,10 +98,10 @@ class WebsocketManager {
|
||||
return null
|
||||
}
|
||||
|
||||
if (
|
||||
socket.connected === true &&
|
||||
typeof socket.disconnect === "function"
|
||||
) {
|
||||
const isConnected =
|
||||
socket.connected === true || socket.state?.connected === true
|
||||
|
||||
if (isConnected && typeof socket.disconnect === "function") {
|
||||
await socket.disconnect()
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user