fix: 处理边界条件
This commit is contained in:
1 parent
77ab9c8e7a
commit
695f6752f9
1 file changed
+1
-1
@@ -26,7 +26,7 @@ export class OB11ActiveWebSocketAdapter implements IOB11NetworkAdapter {
|
||||
}
|
||||
|
||||
onEvent<T extends OB11EmitEventContent>(event: T) {
|
||||
if (this.connection) {
|
||||
if (this.connection && this.connection.readyState === WebSocket.OPEN) {
|
||||
this.connection.send(JSON.stringify(event));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user