1
0
mirror of https://gitlab.com/comunic/comunicmobile synced 2025-06-19 08:15:16 +00:00

Fix unread conversations dropdown

This commit is contained in:
2021-04-25 16:12:36 +02:00
parent 88217202f8
commit de7feb36ce
2 changed files with 22 additions and 2 deletions

View File

@ -9,7 +9,19 @@ class UnreadConversationsList extends AbstractList<UnreadConversation> {
/// Get the ID of the users included in this list
Set<int> get usersID {
final set = Set<int>();
forEach((element) => set.addAll(element.message.usersID));
forEach((element) {
set.addAll(element.conv.membersID);
set.addAll(element.message.usersID);
});
return set;
}
/// Get the ID of the groups references ind this list
Set<int> get groupsID {
final set = Set<int>();
forEach((element) {
if (element.conv.isGroupConversation) set.add(element.conv.groupID);
});
return set;
}
}