mirror of
https://github.com/zadam/trilium.git
synced 2025-11-02 20:49:01 +01:00
fix(export/share): tree error in prod
This commit is contained in:
parent
6d446c5b27
commit
3ebfee8bd2
@ -88,8 +88,11 @@ export function renderNoteContent(note: SNote) {
|
|||||||
|
|
||||||
const ancestors: string[] = [];
|
const ancestors: string[] = [];
|
||||||
let notePointer = note;
|
let notePointer = note;
|
||||||
while (notePointer.parents[0].noteId !== subRoot.note?.noteId) {
|
while (notePointer.parents[0]?.noteId !== subRoot.note?.noteId) {
|
||||||
const pointerParent = notePointer.parents[0];
|
const pointerParent = notePointer.parents[0];
|
||||||
|
if (!pointerParent) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
ancestors.push(pointerParent.noteId);
|
ancestors.push(pointerParent.noteId);
|
||||||
notePointer = pointerParent;
|
notePointer = pointerParent;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user