move auto archive hook closer to the save call
This commit is contained in:
parent
e8a26a6b4d
commit
219415f434
1 changed files with 3 additions and 3 deletions
|
@ -280,9 +280,6 @@ enyo.kind({
|
||||||
this.cacheChanges = "COMMIT";
|
this.cacheChanges = "COMMIT";
|
||||||
this.owner.addTodo();
|
this.owner.addTodo();
|
||||||
this.completeItem = false;
|
this.completeItem = false;
|
||||||
if (this.owner.preferences["archive"] == true) {
|
|
||||||
this.owner.autoarchive = true;
|
|
||||||
}
|
|
||||||
this.$.todoPopup.close();
|
this.$.todoPopup.close();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -338,6 +335,9 @@ enyo.kind({
|
||||||
}
|
}
|
||||||
this.listRefresh();
|
this.listRefresh();
|
||||||
if (this.owner.preferences["storage"] != "none" && this.cacheChanges != "START" && this.cacheChanges != "YES") {
|
if (this.owner.preferences["storage"] != "none" && this.cacheChanges != "START" && this.cacheChanges != "YES") {
|
||||||
|
if (this.owner.preferences["archive"] == true && this.completeItem) {
|
||||||
|
this.owner.autoarchive = true;
|
||||||
|
}
|
||||||
console.log("saving list");
|
console.log("saving list");
|
||||||
this.owner.saveFile(
|
this.owner.saveFile(
|
||||||
this.owner.preferences["filepath"], this.owner.todoList);
|
this.owner.preferences["filepath"], this.owner.todoList);
|
||||||
|
|
Loading…
Reference in a new issue