mirror of
https://github.com/signalapp/Signal-Android.git
synced 2025-12-24 13:08:46 +00:00
Delete attachment transfer files after restore or download.
This commit is contained in:
committed by
jeffrey-signal
parent
ec76372e4d
commit
b9e0d9978b
@@ -352,6 +352,8 @@ class AttachmentDownloadJob private constructor(
|
||||
SignalDatabase.attachments.clearIncrementalMacsForAttachmentAndAnyDuplicates(attachmentId, attachment.remoteKey, attachment.dataHash)
|
||||
markFailed(messageId, attachmentId)
|
||||
}
|
||||
|
||||
attachmentFile.delete()
|
||||
}
|
||||
|
||||
@Throws(InvalidAttachmentException::class)
|
||||
|
||||
@@ -468,6 +468,8 @@ class RestoreAttachmentJob private constructor(
|
||||
SignalDatabase.attachments.clearIncrementalMacsForAttachmentAndAnyDuplicates(attachmentId, attachment.remoteKey, attachment.dataHash)
|
||||
markFailed(attachmentId)
|
||||
}
|
||||
|
||||
attachmentFile.delete()
|
||||
}
|
||||
|
||||
private fun markFailed(attachmentId: AttachmentId) {
|
||||
|
||||
Reference in New Issue
Block a user