Merge pull request #3202 from element-hq/renovate/org.matrix.rustcomponents-sdk-android-0.x

Update dependency org.matrix.rustcomponents:sdk-android to v0.2.32
This commit is contained in:
ganfra 2024-07-16 18:01:07 +02:00 committed by GitHub
commit 181a7a0718
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 13 additions and 11 deletions

View file

@ -82,8 +82,6 @@ class RustMatrixClientFactory @Inject constructor(
.addRootCertificates(userCertificatesProvider.provides())
.autoEnableBackups(true)
.autoEnableCrossSigning(true)
// FIXME Quick and dirty fix for stopping version requests on startup https://github.com/matrix-org/matrix-rust-sdk/pull/1376
.serverVersions(listOf("v1.0", "v1.1", "v1.2", "v1.3", "v1.4", "v1.5"))
.run {
// Workaround for non-nullable proxy parameter in the SDK, since each call to the ClientBuilder returns a new reference we need to keep
proxyProvider.provides()?.let { proxy(it) } ?: this

View file

@ -328,16 +328,20 @@ class RustTimeline(
runCatching<Unit> {
when {
originalEventId != null -> {
inner.editByEventId(
newContent = messageEventContentFromParts(body, htmlBody).withMentions(mentions.map()),
eventId = originalEventId.value,
)
inner.getEventTimelineItemByEventId(originalEventId.value).use {
inner.edit(
newContent = messageEventContentFromParts(body, htmlBody).withMentions(mentions.map()),
item = it,
)
}
}
transactionId != null -> {
inner.edit(
newContent = messageEventContentFromParts(body, htmlBody).withMentions(mentions.map()),
item = inner.getEventTimelineItemByTransactionId(transactionId.value),
)
inner.getEventTimelineItemByTransactionId(transactionId.value).use {
inner.edit(
newContent = messageEventContentFromParts(body, htmlBody).withMentions(mentions.map()),
item = it,
)
}
}
else -> {
error("Either originalEventId or transactionId must be non null")