mirror of
https://github.com/vector-im/element-web.git
synced 2026-05-05 12:16:53 +02:00
Improve addEventsToTimeline performance scoping WhoIsTypingTile::setState
This commit is contained in:
parent
1751b4ba43
commit
88af74e4a4
@ -87,7 +87,9 @@ export default class WhoIsTypingTile extends React.Component {
|
||||
const userId = event.getSender();
|
||||
// remove user from usersTyping
|
||||
const usersTyping = this.state.usersTyping.filter((m) => m.userId !== userId);
|
||||
this.setState({usersTyping});
|
||||
if (usersTyping.length !== this.state.usersTyping.length) {
|
||||
this.setState({usersTyping});
|
||||
}
|
||||
// abort timer if any
|
||||
this._abortUserTimer(userId);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user