FIX: match drafts using key when deleting
Using "sequence" when removing drafts was buggy, it would remove more than one draft from the stream sometimes.
This commit is contained in:
parent
0e1862013a
commit
84a3da4b18
|
@ -45,7 +45,7 @@ export default RestModel.extend({
|
|||
|
||||
remove(draft) {
|
||||
let content = this.get("content").filter(
|
||||
item => item.sequence !== draft.sequence
|
||||
item => item.draft_key !== draft.draft_key
|
||||
);
|
||||
this.setProperties({ content, itemsLoaded: content.length });
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue