Fix event handler leak in MemberStatusMessageAvatar
A typo led to an event handler leak with the custom status labs feature. A new handler would leak each time you change rooms, which can add up over the course of a long-lived session.
This commit is contained in:
parent
cad9562f8d
commit
03448313e6
1 changed files with 1 additions and 1 deletions
|
@ -63,7 +63,7 @@ export default class MemberStatusMessageAvatar extends React.Component {
|
||||||
user.on("User._unstable_statusMessage", this._onStatusMessageCommitted);
|
user.on("User._unstable_statusMessage", this._onStatusMessageCommitted);
|
||||||
}
|
}
|
||||||
|
|
||||||
componentWillUmount() {
|
componentWillUnmount() {
|
||||||
const { user } = this.props.member;
|
const { user } = this.props.member;
|
||||||
if (!user) {
|
if (!user) {
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in a new issue