store attachment uri as a string

This commit is contained in:
tibbi 2020-12-21 15:29:10 +01:00
parent ceb9896988
commit 4cad413478
5 changed files with 9 additions and 7 deletions

View file

@ -225,7 +225,7 @@ class ThreadAdapter(activity: SimpleActivity, var messages: ArrayList<ThreadItem
if (message.attachment?.attachments?.isNotEmpty() == true) {
for (attachment in message.attachment.attachments) {
val mimetype = attachment.mimetype
val uri = attachment.uri
val uri = attachment.getUri()
if (mimetype.startsWith("image/") || mimetype.startsWith("video/")) {
val imageView = layoutInflater.inflate(R.layout.item_attachment_image, null)
thread_mesage_attachments_holder.addView(imageView)