1
0
mirror of https://github.com/matrix-org/matrix-react-sdk.git synced 2025-11-20 16:22:28 +03:00

Simplify event name as it's the only one

This commit is contained in:
David Baker
2018-07-05 20:00:42 +01:00
parent 3f20eb9610
commit b6f854abe4
3 changed files with 6 additions and 6 deletions

View File

@@ -155,7 +155,7 @@ module.exports = React.createClass({
this._roomStoreToken = RoomViewStore.addListener(this._onRoomViewStoreUpdate);
this._onRoomViewStoreUpdate(true);
WidgetEchoStore.on('updateRoomWidgetEcho', this._onWidgetEchoStoreUpdate);
WidgetEchoStore.on('update', this._onWidgetEchoStoreUpdate);
},
_onRoomViewStoreUpdate: function(initial) {
@@ -425,7 +425,7 @@ module.exports = React.createClass({
this._roomStoreToken.remove();
}
WidgetEchoStore.removeListener('updateRoomWidgetEcho', this._onWidgetEchoStoreUpdate);
WidgetEchoStore.removeListener('update', this._onWidgetEchoStoreUpdate);
// cancel any pending calls to the rate_limited_funcs
this._updateRoomMembers.cancelPendingCall();

View File

@@ -58,7 +58,7 @@ module.exports = React.createClass({
componentWillMount: function() {
ScalarMessaging.startListening();
MatrixClientPeg.get().on('RoomState.events', this.onRoomStateEvents);
WidgetEchoStore.on('updateRoomWidgetEcho', this._updateApps);
WidgetEchoStore.on('update', this._updateApps);
},
componentDidMount: function() {
@@ -84,7 +84,7 @@ module.exports = React.createClass({
if (MatrixClientPeg.get()) {
MatrixClientPeg.get().removeListener('RoomState.events', this.onRoomStateEvents);
}
WidgetEchoStore.removeListener('updateRoomWidgetEcho', this._updateApps);
WidgetEchoStore.removeListener('update', this._updateApps);
dis.unregister(this.dispatcherRef);
},