Merge pull request #1752 from matrix-org/dbkr/roomliststore_unregister

Remove RoomListStore listener
pull/21833/head
David Baker 2018-02-15 13:35:08 +00:00 committed by GitHub
commit 0c5b0fd52c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -191,6 +191,10 @@ module.exports = React.createClass({
this._tagStoreToken.remove();
}
if (this._roomListStoreToken) {
this._roomListStoreToken.remove();
}
if (this._groupStoreTokens.length > 0) {
// NB: GroupStore is not a Flux.Store
this._groupStoreTokens.forEach((token) => token.unregister());