Merge pull request #2513 from jryans/null-dvb
Fix unmount TypeError in `DeviceVerifyButtons`
This commit is contained in:
commit
4ac617c72b
1 changed files with 3 additions and 1 deletions
|
@ -42,7 +42,9 @@ export default React.createClass({
|
||||||
|
|
||||||
componentWillUnmount: function() {
|
componentWillUnmount: function() {
|
||||||
const cli = MatrixClientPeg.get();
|
const cli = MatrixClientPeg.get();
|
||||||
cli.removeListener("deviceVerificationChanged", this.onDeviceVerificationChanged);
|
if (cli) {
|
||||||
|
cli.removeListener("deviceVerificationChanged", this.onDeviceVerificationChanged);
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
onDeviceVerificationChanged: function(userId, deviceId, deviceInfo) {
|
onDeviceVerificationChanged: function(userId, deviceId, deviceInfo) {
|
||||||
|
|
Loading…
Reference in a new issue