mirror of
https://github.com/vector-im/element-web.git
synced 2025-10-17 10:21:44 +02:00
Check matrix client exists when stopping
This commit is contained in:
parent
7044410a13
commit
cdd73e6e1f
@ -52,7 +52,9 @@ class ActiveWidgetStore extends EventEmitter {
|
||||
}
|
||||
|
||||
stop() {
|
||||
if (MatrixClientPeg.get()) {
|
||||
MatrixClientPeg.get().removeListener('RoomState.events', this.onRoomStateEvents);
|
||||
}
|
||||
this._capsByWidgetId = {};
|
||||
this._widgetMessagingByWidgetId = {};
|
||||
this._roomIdByWidgetId = {};
|
||||
|
Loading…
x
Reference in New Issue
Block a user