Skip to content

Commit

Permalink
Merge pull request #7519 from vector-im/bugfix/fre/unencrypted_media_…
Browse files Browse the repository at this point in the history
…event_json_type

Fix bad content types when sending unencrypted media event with additional content data
  • Loading branch information
Florian14 authored Nov 4, 2022
2 parents 4621488 + c0ba2f2 commit ac0d823
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions changelog.d/7519.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Voice Broadcast - Fix error on voice messages in unencrypted rooms
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,7 @@ internal class UploadContentWorker(val context: Context, params: WorkerParameter
newAttachmentAttributes: NewAttachmentAttributes
) {
localEchoRepository.updateEcho(eventId) { _, event ->
val content: Content? = event.asDomain().content
val content: Content? = event.asDomain(castJsonNumbers = true).content
val messageContent: MessageContent? = content.toModel()
// Retrieve potential additional content from the original event
val additionalContent = content.orEmpty() - messageContent?.toContent().orEmpty().keys
Expand Down

0 comments on commit ac0d823

Please sign in to comment.