From e7909d25c6f4c625e21ae3458e4388588976b51d Mon Sep 17 00:00:00 2001 From: zadam Date: Wed, 7 Apr 2021 21:12:55 +0200 Subject: [PATCH] fix linking to notes --- src/services/note_cache/note_cache_service.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/services/note_cache/note_cache_service.js b/src/services/note_cache/note_cache_service.js index 737a1c081..3d685c681 100644 --- a/src/services/note_cache/note_cache_service.js +++ b/src/services/note_cache/note_cache_service.js @@ -125,10 +125,10 @@ function getNoteTitleForPath(notePathArray) { * - this means that archived paths is returned only if there's no non-archived path * - you can check whether returned path is archived using isArchived() */ -function getSomePath(note) { +function getSomePath(note, path = []) { // first try to find note within hoisted note, otherwise take any existing note path - return getSomePathInner(note, [], true) - || getSomePathInner(note, [], false); + return getSomePathInner(note, path, true) + || getSomePathInner(note, path, false); } function getSomePathInner(note, path, respectHoistng) {