mirror of
https://github.com/vector-im/element-android.git
synced 2024-11-16 02:05:06 +08:00
Do not delete voice message file to be able to resend.
This commit is contained in:
parent
3a387c5e32
commit
13aee7d162
1
changelog.d/4006.bugfix
Normal file
1
changelog.d/4006.bugfix
Normal file
@ -0,0 +1 @@
|
||||
Voice Message not sendable if recorded while flight mode was on
|
@ -291,6 +291,11 @@ internal class UploadContentWorker(val context: Context, params: WorkerParameter
|
||||
filesToDelete.forEach {
|
||||
tryOrNull { it.delete() }
|
||||
}
|
||||
|
||||
// Delete the temporary voice message file
|
||||
if (params.attachment.type == ContentAttachmentData.Type.AUDIO && params.attachment.mimeType == MimeTypes.Ogg) {
|
||||
context.contentResolver.delete(params.attachment.queryUri, null, null)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1095,8 +1095,6 @@ class RoomDetailFragment @Inject constructor(
|
||||
|
||||
textComposerViewModel.handle(TextComposerAction.SaveDraft(views.composerLayout.text.toString()))
|
||||
|
||||
// We should improve the UX to support going into playback mode when paused and delete the media when the view is destroyed.
|
||||
roomDetailViewModel.handle(RoomDetailAction.EndAllVoiceActions)
|
||||
views.voiceMessageRecorderView.initVoiceRecordingViews()
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user