Rust sdk : handle api changes (draft and edit)

This commit is contained in:
ganfra
2024-07-01 17:50:29 +02:00
parent 0826a94a5d
commit 2a7154b53e
2 changed files with 3 additions and 3 deletions

View File

@@ -19,8 +19,8 @@ package io.element.android.libraries.matrix.impl.room.draft
import io.element.android.libraries.matrix.api.core.EventId
import io.element.android.libraries.matrix.api.room.draft.ComposerDraft
import io.element.android.libraries.matrix.api.room.draft.ComposerDraftType
import uniffi.matrix_sdk_base.ComposerDraft as RustComposerDraft
import uniffi.matrix_sdk_base.ComposerDraftType as RustComposerDraftType
import org.matrix.rustcomponents.sdk.ComposerDraft as RustComposerDraft
import org.matrix.rustcomponents.sdk.ComposerDraftType as RustComposerDraftType
internal fun ComposerDraft.into(): RustComposerDraft {
return RustComposerDraft(

View File

@@ -327,7 +327,7 @@ class RustTimeline(
runCatching<Unit> {
when {
originalEventId != null -> {
inner.edit(
inner.editByEventId(
newContent = messageEventContentFromParts(body, htmlBody).withMentions(mentions.map()),
eventId = originalEventId.value,
)