Merge pull request #1181 from vector-im/feature/update_shield_logic
Update shield logic for DM
This commit is contained in:
commit
024c62515c
|
@ -7,6 +7,7 @@ Features ✨:
|
||||||
|
|
||||||
Improvements 🙌:
|
Improvements 🙌:
|
||||||
- Verification DM / Handle concurrent .start after .ready (#794)
|
- Verification DM / Handle concurrent .start after .ready (#794)
|
||||||
|
- CrossSigning / Update Shield Logic for DM (#963)
|
||||||
- Xsigning | Complete security new session design update (#1135)
|
- Xsigning | Complete security new session design update (#1135)
|
||||||
|
|
||||||
Bugfix 🐛:
|
Bugfix 🐛:
|
||||||
|
|
|
@ -161,7 +161,15 @@ internal class RoomSummaryUpdater @Inject constructor(
|
||||||
roomSummaryEntity.otherMemberIds.clear()
|
roomSummaryEntity.otherMemberIds.clear()
|
||||||
roomSummaryEntity.otherMemberIds.addAll(otherRoomMembers)
|
roomSummaryEntity.otherMemberIds.addAll(otherRoomMembers)
|
||||||
if (roomSummaryEntity.isEncrypted) {
|
if (roomSummaryEntity.isEncrypted) {
|
||||||
eventBus.post(SessionToCryptoRoomMembersUpdate(roomId, roomSummaryEntity.otherMemberIds.toList() + userId))
|
// The set of “all users” depends on the type of room:
|
||||||
|
// For regular / topic rooms, all users including yourself, are considered when decorating a room
|
||||||
|
// For 1:1 and group DM rooms, all other users (i.e. excluding yourself) are considered when decorating a room
|
||||||
|
val listToCheck = if (roomSummaryEntity.isDirect) {
|
||||||
|
roomSummaryEntity.otherMemberIds.toList()
|
||||||
|
} else {
|
||||||
|
roomSummaryEntity.otherMemberIds.toList() + userId
|
||||||
|
}
|
||||||
|
eventBus.post(SessionToCryptoRoomMembersUpdate(roomId, listToCheck))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue