Make UI respond to thread events

This commit is contained in:
Germain Souquet 2021-08-17 17:42:47 +01:00
parent 458f860a26
commit 95f4513bd2
7 changed files with 44 additions and 17 deletions

View file

@ -52,13 +52,6 @@ class ThreadView extends React.Component<IProps, IState> {
public componentDidMount(): void {
this.room.on("Thread.update", this.onThreadEventReceived);
this.room.on("Thread.ready", this.onThreadEventReceived);
this.updateThreads(() => {
this.state.threads.forEach(thread => {
if (!thread.ready) {
thread.fetchReplyChain();
}
});
});
}
public componentWillUnmount(): void {