mirror of
https://github.com/zadam/trilium.git
synced 2025-11-15 17:55:52 +01:00
change the heuristics to choose the best note path when ambiguous/incomplete/just noteId is provided, #1711
This commit is contained in:
@@ -16,10 +16,10 @@ async function unhoist() {
|
||||
}
|
||||
|
||||
function isTopLevelNode(node) {
|
||||
return isRootNode(node.getParent());
|
||||
return isHoistedNode(node.getParent());
|
||||
}
|
||||
|
||||
function isRootNode(node) {
|
||||
function isHoistedNode(node) {
|
||||
// even though check for 'root' should not be necessary, we keep it just in case
|
||||
return node.data.noteId === "root"
|
||||
|| node.data.noteId === getHoistedNoteId();
|
||||
@@ -55,6 +55,6 @@ export default {
|
||||
getHoistedNoteId,
|
||||
unhoist,
|
||||
isTopLevelNode,
|
||||
isRootNode,
|
||||
isHoistedNode,
|
||||
checkNoteAccess
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user