Use original uri as id for attachment selections

This commit is contained in:
Naveen 2022-11-06 17:15:49 +05:30
parent c1c60e8971
commit 0eb5b79188
2 changed files with 5 additions and 2 deletions

View file

@ -9,6 +9,7 @@ import com.simplemobiletools.smsmessenger.helpers.ATTACHMENT_MEDIA
import com.simplemobiletools.smsmessenger.helpers.ATTACHMENT_VCARD
data class AttachmentSelection(
val id: String,
val uri: Uri,
val mimetype: String,
val filename: String,
@ -25,7 +26,7 @@ data class AttachmentSelection(
}
fun areItemsTheSame(first: AttachmentSelection, second: AttachmentSelection): Boolean {
return first.uri == second.uri
return first.id == second.id
}
fun areContentsTheSame(first: AttachmentSelection, second: AttachmentSelection): Boolean {