fix: only resume AttachmentDownloadJobs and fix boolean logic on returning early in download job

This commit is contained in:
jubb
2021-07-09 15:17:07 +10:00
parent 9dfd051e63
commit 1ee1d1795d
2 changed files with 3 additions and 2 deletions

View File

@@ -76,7 +76,7 @@ class AttachmentDownloadJob(val attachmentID: Long, val databaseMessageID: Long)
handleFailure(Error.NoSender, null)
return
}
if (!threadRecipient.isGroupRecipient && (!contact.isTrusted || storage.getUserPublicKey() != sender.address.serialize())) {
if (!threadRecipient.isGroupRecipient && !(contact.isTrusted || storage.getUserPublicKey() != sender.address.serialize())) {
Log.e("Loki", "Thread isn't a group recipient, or contact isn't trusted or self-send")
return
}