fix creating new note

This commit is contained in:
zadam
2020-08-28 14:29:20 +02:00
parent 30e84321f9
commit 9873dd1242
2 changed files with 14 additions and 6 deletions

View File

@@ -56,6 +56,10 @@ class NoteShort {
}
addParent(parentNoteId, branchId) {
if (parentNoteId === 'none') {
return;
}
if (!this.parents.includes(parentNoteId)) {
this.parents.push(parentNoteId);
}
@@ -451,7 +455,7 @@ class NoteShort {
}
for (const parentNote of this.getParentNotes()) {
if (parentNote.hasAncestor(ancestorNote)) {console.log(parentNote);
if (parentNote.hasAncestor(ancestorNote)) {
return true;
}
}