Make UI respond to thread events
This commit is contained in:
parent
458f860a26
commit
95f4513bd2
7 changed files with 44 additions and 17 deletions
|
@ -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 {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue