Fix deleted attachments reappearing

This commit is contained in:
Shadowfacts 2023-05-04 10:12:44 -04:00
parent bbdb7fe41f
commit 098c4254d4
1 changed files with 3 additions and 1 deletions

View File

@ -76,7 +76,9 @@ class AttachmentsListController: ViewController {
}
private func deleteAttachments(at indices: IndexSet) {
draft.attachments.removeObjects(at: indices)
var array = draft.draftAttachments
array.remove(atOffsets: indices)
draft.attachments = NSMutableOrderedSet(array: array)
}
private func insertAttachments(at offset: Int, itemProviders: [NSItemProvider]) {