repository has now first level cache

This commit is contained in:
zadam
2020-04-06 20:59:04 +02:00
parent 081693f263
commit 5c0355718f
7 changed files with 45 additions and 20 deletions

View File

@@ -544,16 +544,22 @@ async function deleteBranch(branch, deleteId, taskContext) {
note.deleteId = deleteId;
await note.save();
console.log("Deleting note", note.noteId);
for (const attribute of await note.getOwnedAttributes()) {
attribute.isDeleted = true;
attribute.deleteId = deleteId;
await attribute.save();
console.log("Deleting note's", note.noteId, "attribute", attribute.attributeId);
}
for (const relation of await note.getTargetRelations()) {
relation.isDeleted = true;
relation.deleteId = deleteId;
await relation.save();
console.log("Deleting note's", note.noteId, "target relation", relation.attributeId);
}
return true;