diff --git a/CHANGES.md b/CHANGES.md index 4100031b36..e922bec768 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,7 +1,14 @@ +Changes in RiotX 0.14.3 (2020-02-03) +=================================================== + +Bugfix 🐛: + - Fix Exception in DeviceListManager + Changes in RiotX 0.14.2 (2020-02-02) =================================================== -Fix RiotX not starting issue +Bugfix 🐛: + - Fix RiotX not starting issue Changes in RiotX 0.14.1 (2020-02-02) =================================================== diff --git a/matrix-sdk-android/src/main/java/im/vector/matrix/android/internal/crypto/DeviceListManager.kt b/matrix-sdk-android/src/main/java/im/vector/matrix/android/internal/crypto/DeviceListManager.kt index bc5add34a1..87b2093e2d 100755 --- a/matrix-sdk-android/src/main/java/im/vector/matrix/android/internal/crypto/DeviceListManager.kt +++ b/matrix-sdk-android/src/main/java/im/vector/matrix/android/internal/crypto/DeviceListManager.kt @@ -319,10 +319,11 @@ internal class DeviceListManager @Inject constructor(private val cryptoStore: IM for (userId in filteredUsers) { // al devices = val models = response.deviceKeys?.get(userId)?.mapValues { entry -> CryptoInfoMapper.map(entry.value) } - ?.toMutableMap() + Timber.v("## doKeyDownloadForUsers() : Got keys for $userId : $models") if (!models.isNullOrEmpty()) { + val workingCopy = models.toMutableMap() for ((deviceId, deviceInfo) in models) { // Get the potential previously store device keys for this device val previouslyStoredDeviceKeys = cryptoStore.getUserDevice(userId, deviceId) @@ -335,21 +336,21 @@ internal class DeviceListManager @Inject constructor(private val cryptoStore: IM // Validate received keys if (!validateDeviceKeys(deviceInfo, userId, deviceId, previouslyStoredDeviceKeys)) { // New device keys are not valid. Do not store them - models.remove(deviceId) + workingCopy.remove(deviceId) if (null != previouslyStoredDeviceKeys) { // But keep old validated ones if any - models[deviceId] = previouslyStoredDeviceKeys + workingCopy[deviceId] = previouslyStoredDeviceKeys } } else if (null != previouslyStoredDeviceKeys) { // The verified status is not sync'ed with hs. // This is a client side information, valid only for this client. // So, transfer its previous value - models[deviceId]!!.trustLevel = previouslyStoredDeviceKeys.trustLevel + workingCopy[deviceId]!!.trustLevel = previouslyStoredDeviceKeys.trustLevel } } // Update the store // Note that devices which aren't in the response will be removed from the stores - cryptoStore.storeUserDevices(userId, models) + cryptoStore.storeUserDevices(userId, workingCopy) } // Handle cross signing keys update diff --git a/vector/build.gradle b/vector/build.gradle index 6321b5c4ec..96744ec224 100644 --- a/vector/build.gradle +++ b/vector/build.gradle @@ -16,7 +16,7 @@ androidExtensions { ext.versionMajor = 0 ext.versionMinor = 14 -ext.versionPatch = 2 +ext.versionPatch = 3 static def getGitTimestamp() { def cmd = 'git show -s --format=%ct'