Fix listener removal in verification tile
Fixes https://github.com/matrix-org/riot-web-rageshakes/issues/2202
This commit is contained in:
parent
f89ae19d76
commit
110c5f0e61
1 changed files with 4 additions and 1 deletions
|
@ -40,7 +40,10 @@ export default class MKeyVerificationConclusion extends React.Component {
|
||||||
if (request) {
|
if (request) {
|
||||||
request.off("change", this._onRequestChanged);
|
request.off("change", this._onRequestChanged);
|
||||||
}
|
}
|
||||||
MatrixClientPeg.removeListener("userTrustStatusChanged", this._onTrustChanged);
|
const cli = MatrixClientPeg.get();
|
||||||
|
if (cli) {
|
||||||
|
cli.removeListener("userTrustStatusChanged", this._onTrustChanged);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
_onRequestChanged = () => {
|
_onRequestChanged = () => {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue