delete attributes when deleting note

This commit is contained in:
azivner
2018-08-15 15:27:22 +02:00
parent 3204291463
commit 4513651e12
5 changed files with 35 additions and 2 deletions

View File

@@ -34,7 +34,12 @@ function getNotePath(node) {
async function getNoteTitle(noteId, parentNoteId = null) {
utils.assertArguments(noteId);
let {title} = await treeCache.getNote(noteId);
const note = await treeCache.getNote(noteId);
if (!note) {
return "[not found]";
}
let {title} = note;
if (parentNoteId !== null) {
const branch = await treeCache.getBranchByChildParent(noteId, parentNoteId);