De-register listener.

pull/21833/head
Richard Lewis 2018-01-08 11:32:23 +00:00
parent 54d128658e
commit dc1423052f
1 changed files with 1 additions and 0 deletions

View File

@ -229,6 +229,7 @@ export default React.createClass({
componentWillUnmount() { componentWillUnmount() {
this.widgetMessaging.stopListening(); this.widgetMessaging.stopListening();
this.widgetMessaging.removeEndpoint(this.props.id, this.props.url); this.widgetMessaging.removeEndpoint(this.props.id, this.props.url);
dis.unregister(this._onAction);
window.removeEventListener('message', this._onMessage); window.removeEventListener('message', this._onMessage);
}, },