newState and oldState on ConnectionStateUpdatedEvent

This commit is contained in:
Hiroshi Horie
2022-03-04 19:38:25 +09:00
parent d278310748
commit 21591e46e3
4 changed files with 32 additions and 12 deletions
+1 -1
View File
@@ -592,7 +592,7 @@ class Engine extends Disposable with EventsEmittable<EngineEvent> {
events.emit(event);
})
..on<SignalConnectionStateUpdatedEvent>((event) async {
if (event.connectionState == ConnectionState.disconnected) {
if (event.newState == ConnectionState.disconnected) {
await _onDisconnected(DisconnectReason.signal);
}
// Relay to Room