Filter empty threads out from list (#8008)
This commit is contained in:
parent
93bde40568
commit
3d6dece344
1 changed files with 1 additions and 1 deletions
|
@ -91,8 +91,8 @@ export async function getThreadTimelineSet(
|
|||
});
|
||||
|
||||
Array.from(room.threads)
|
||||
.sort(([, threadA], [, threadB]) => threadA.replyToEvent.getTs() - threadB.replyToEvent.getTs())
|
||||
.forEach(([, thread]) => {
|
||||
if (thread.length === 0) return;
|
||||
const currentUserParticipated = thread.events.some(event => event.getSender() === client.getUserId());
|
||||
if (filterType !== ThreadFilterType.My || currentUserParticipated) {
|
||||
timelineSet.getLiveTimeline().addEvent(thread.rootEvent, false);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue