Merge branch 'develop' into feature/target-sdk-29
This commit is contained in:
commit
443d45db6a
|
@ -8,6 +8,7 @@ Features ✨:
|
|||
Improvements 🙌:
|
||||
- Verification DM / Handle concurrent .start after .ready (#794)
|
||||
- Reimplementation of multiple attachment picker
|
||||
- CrossSigning / Update Shield Logic for DM (#963)
|
||||
- Xsigning | Complete security new session design update (#1135)
|
||||
|
||||
Bugfix 🐛:
|
||||
|
|
|
@ -102,6 +102,7 @@ internal object RealmCryptoStoreMigration : RealmMigration {
|
|||
?.addRealmObjectField(DeviceInfoEntityFields.TRUST_LEVEL_ENTITY.`$`, trustLevelentityEntitySchema)
|
||||
?.transform { obj ->
|
||||
|
||||
try {
|
||||
val oldSerializedData = obj.getString("deviceInfoData")
|
||||
deserializeFromRealm<MXDeviceInfo>(oldSerializedData)?.let { oldDevice ->
|
||||
|
||||
|
@ -135,6 +136,11 @@ internal object RealmCryptoStoreMigration : RealmMigration {
|
|||
obj.setString(DeviceInfoEntityFields.SIGNATURE_MAP_JSON, mapMigrationAdapter.toJson(oldDevice.signatures))
|
||||
obj.setString(DeviceInfoEntityFields.UNSIGNED_MAP_JSON, mapMigrationAdapter.toJson(oldDevice.unsigned))
|
||||
}
|
||||
} catch (failure: Throwable) {
|
||||
Timber.w(failure, "Crypto Data base migration error")
|
||||
// an unfortunate refactor did modify that class, making deserialization failing
|
||||
// so we just skip and ignore..
|
||||
}
|
||||
}
|
||||
?.removeField("deviceInfoData")
|
||||
}
|
||||
|
|
|
@ -161,7 +161,15 @@ internal class RoomSummaryUpdater @Inject constructor(
|
|||
roomSummaryEntity.otherMemberIds.clear()
|
||||
roomSummaryEntity.otherMemberIds.addAll(otherRoomMembers)
|
||||
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