Make threads events indexed by the index manager (#7442)
This commit is contained in:
parent
defbe16448
commit
fdc6082c83
2 changed files with 2 additions and 18 deletions
|
@ -135,16 +135,7 @@ export default class ThreadView extends React.Component<IProps, IState> {
|
|||
private setupThread = (mxEv: MatrixEvent) => {
|
||||
let thread = this.props.room.threads.get(mxEv.getId());
|
||||
if (!thread) {
|
||||
const client = MatrixClientPeg.get();
|
||||
// Do not attach this thread object to the event for now
|
||||
// TODO: When local echo gets reintroduced it will be important
|
||||
// to add that back in, and the threads model should go through the
|
||||
// same reconciliation algorithm as events
|
||||
thread = new Thread(
|
||||
[mxEv],
|
||||
this.props.room,
|
||||
client,
|
||||
);
|
||||
thread = this.props.room.createThread([mxEv]);
|
||||
}
|
||||
thread.on(ThreadEvent.Update, this.updateThread);
|
||||
thread.once(ThreadEvent.Ready, this.updateThread);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue