mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-02-26 04:33:36 +00:00
Allow NEEDS_RESTORE attachments to be considered as 'couldBeOnArchiveCdn'.
This commit is contained in:
committed by
Michelle Tang
parent
1a1ddbfa39
commit
9903a664d4
@@ -227,7 +227,7 @@ private fun DatabaseAttachment.toRemoteAttachmentType(): AttachmentType {
|
||||
}
|
||||
|
||||
val activelyOnArchiveCdn = this.archiveTransferState == AttachmentTable.ArchiveTransferState.FINISHED
|
||||
val couldBeOnArchiveCdn = this.transferState == AttachmentTable.TRANSFER_PROGRESS_DONE && this.archiveTransferState != AttachmentTable.ArchiveTransferState.PERMANENT_FAILURE
|
||||
val couldBeOnArchiveCdn = (this.transferState == AttachmentTable.TRANSFER_PROGRESS_DONE || this.transferState == AttachmentTable.TRANSFER_NEEDS_RESTORE) && this.archiveTransferState != AttachmentTable.ArchiveTransferState.PERMANENT_FAILURE
|
||||
|
||||
if (this.dataHash != null && (activelyOnArchiveCdn || couldBeOnArchiveCdn)) {
|
||||
return AttachmentType.ARCHIVE
|
||||
|
||||
Reference in New Issue
Block a user