Fix deleted attachments reappearing
This commit is contained in:
parent
bbdb7fe41f
commit
098c4254d4
|
@ -76,7 +76,9 @@ class AttachmentsListController: ViewController {
|
||||||
}
|
}
|
||||||
|
|
||||||
private func deleteAttachments(at indices: IndexSet) {
|
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]) {
|
private func insertAttachments(at offset: Int, itemProviders: [NSItemProvider]) {
|
||||||
|
|
Loading…
Reference in New Issue