Skip to content

Commit c3fa399

Browse files
committed
Merge branch 'release/1.6.26' into main
2 parents de6b7c5 + a0d1b2d commit c3fa399

File tree

10 files changed

+144
-72
lines changed

10 files changed

+144
-72
lines changed

CHANGES.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
Changes in Element v1.6.26 (2024-12-20)
2+
=======================================
3+
4+
Other changes
5+
-------------
6+
- Bump org.matrix.rustcomponents:crypto-android from 0.5.0 to 0.6.0 based on matrix-sdk-crypto-0.9.0 ([#8960](https://github.com/element-hq/element-android/issues/8960))
7+
8+
19
Changes in Element v1.6.24 (2024-11-19)
210
=======================================
311

Gemfile.lock

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -207,8 +207,7 @@ GEM
207207
trailblazer-option (>= 0.1.1, < 0.2.0)
208208
uber (< 0.2.0)
209209
retriable (3.1.2)
210-
rexml (3.2.9)
211-
strscan
210+
rexml (3.3.9)
212211
rouge (2.0.7)
213212
ruby2_keywords (0.0.5)
214213
rubyzip (2.3.2)
@@ -224,7 +223,6 @@ GEM
224223
simctl (1.6.10)
225224
CFPropertyList
226225
naturally
227-
strscan (3.1.0)
228226
terminal-notifier (2.0.0)
229227
terminal-table (3.0.2)
230228
unicode-display_width (>= 1.1.1, < 3)
@@ -239,13 +237,13 @@ GEM
239237
unf_ext (0.0.9.1)
240238
unicode-display_width (2.5.0)
241239
word_wrap (1.0.0)
242-
xcodeproj (1.24.0)
240+
xcodeproj (1.25.1)
243241
CFPropertyList (>= 2.3.3, < 4.0)
244242
atomos (~> 0.1.3)
245243
claide (>= 1.0.2, < 2.0)
246244
colored2 (~> 3.1)
247245
nanaimo (~> 0.3.0)
248-
rexml (~> 3.2.4)
246+
rexml (>= 3.3.6, < 4.0)
249247
xcpretty (0.3.0)
250248
rouge (~> 2.0.7)
251249
xcpretty-travis-formatter (1.0.1)
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Main changes in this version: crypto sdk upgrade.
2+
Full changelog: https://github.com/element-hq/element-android/releases

matrix-sdk-android/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ android {
6262
// that the app's state is completely cleared between tests.
6363
testInstrumentationRunnerArguments clearPackageData: 'true'
6464

65-
buildConfigField "String", "SDK_VERSION", "\"1.6.24\""
65+
buildConfigField "String", "SDK_VERSION", "\"1.6.26\""
6666

6767
buildConfigField "String", "GIT_SDK_REVISION", "\"${gitRevision()}\""
6868
buildConfigField "String", "GIT_SDK_REVISION_UNIX_DATE", "\"${gitRevisionUnixDate()}\""
@@ -221,7 +221,7 @@ dependencies {
221221

222222
implementation libs.google.phonenumber
223223

224-
implementation("org.matrix.rustcomponents:crypto-android:0.5.0")
224+
implementation("org.matrix.rustcomponents:crypto-android:0.6.0")
225225
// api project(":library:rustCrypto")
226226

227227
testImplementation libs.tests.junit

matrix-sdk-android/src/main/java/org/matrix/android/sdk/internal/crypto/store/db/migration/MigrateCryptoTo024.kt

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
package org.matrix.android.sdk.internal.crypto.store.db.migration
1818

1919
import io.realm.DynamicRealm
20+
import org.matrix.android.sdk.internal.extensions.safeRemove
2021
import org.matrix.android.sdk.internal.util.database.RealmMigrator
2122

2223
internal class MigrateCryptoTo024(realm: DynamicRealm) : RealmMigrator(realm, 24) {
@@ -32,20 +33,20 @@ internal class MigrateCryptoTo024(realm: DynamicRealm) : RealmMigrator(realm, 24
3233
get("CryptoRoomEntity")?.removeField("outboundSessionInfo")
3334

3435
// Warning: order is important, first remove classes that depends on others.
35-
remove("UserEntity")
36-
remove("DeviceInfoEntity")
37-
remove("CrossSigningInfoEntity")
38-
remove("KeyInfoEntity")
39-
remove("TrustLevelEntity")
40-
remove("KeysBackupDataEntity")
41-
remove("OlmInboundGroupSessionEntity")
42-
remove("OlmSessionEntity")
43-
remove("AuditTrailEntity")
44-
remove("OutgoingKeyRequestEntity")
45-
remove("KeyRequestReplyEntity")
46-
remove("WithHeldSessionEntity")
47-
remove("SharedSessionEntity")
48-
remove("OutboundGroupSessionInfoEntity")
36+
safeRemove("UserEntity")
37+
safeRemove("DeviceInfoEntity")
38+
safeRemove("CrossSigningInfoEntity")
39+
safeRemove("KeyInfoEntity")
40+
safeRemove("TrustLevelEntity")
41+
safeRemove("KeysBackupDataEntity")
42+
safeRemove("OlmInboundGroupSessionEntity")
43+
safeRemove("OlmSessionEntity")
44+
safeRemove("AuditTrailEntity")
45+
safeRemove("OutgoingKeyRequestEntity")
46+
safeRemove("KeyRequestReplyEntity")
47+
safeRemove("WithHeldSessionEntity")
48+
safeRemove("SharedSessionEntity")
49+
safeRemove("OutboundGroupSessionInfoEntity")
4950
}
5051
}
5152
}

matrix-sdk-android/src/main/java/org/matrix/android/sdk/internal/extensions/RealmExtensions.kt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ package org.matrix.android.sdk.internal.extensions
1919
import io.realm.RealmList
2020
import io.realm.RealmObject
2121
import io.realm.RealmObjectSchema
22+
import io.realm.RealmSchema
2223
import org.matrix.android.sdk.internal.database.model.HomeServerCapabilitiesEntityFields
2324
import org.matrix.android.sdk.internal.util.fatalError
2425

@@ -52,3 +53,9 @@ internal fun RealmObjectSchema?.forceRefreshOfHomeServerCapabilities(): RealmObj
5253
obj.setLong(HomeServerCapabilitiesEntityFields.LAST_UPDATED_TIMESTAMP, 0)
5354
}
5455
}
56+
57+
internal fun RealmSchema.safeRemove(className: String) {
58+
if (get(className) != null) {
59+
remove(className)
60+
}
61+
}

matrix-sdk-android/src/main/java/org/matrix/android/sdk/internal/session/room/timeline/decorator/UpdatedReplyDecorator.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ internal class UpdatedReplyDecorator(
5959
val isRedactedEvent = timelineEventEntity.root?.asDomain()?.isRedacted() ?: false
6060

6161
val replyText = localEchoEventFactory
62-
.bodyForReply(currentTimelineEvent.getLastMessageContent(), true).formattedText ?: ""
62+
.bodyForReply(currentTimelineEvent.getLastMessageContent(), true).takeFormatted()
6363

6464
val newContent = localEchoEventFactory.createReplyTextContent(
6565
timelineEventMapper.map(timelineEventEntity),

0 commit comments

Comments
 (0)