mirror of
https://github.com/zadam/trilium.git
synced 2025-11-01 19:05:59 +01:00
tree utils as a module
This commit is contained in:
@@ -42,7 +42,7 @@ const encryption = (function() {
|
||||
open: () => {
|
||||
if (!modal) {
|
||||
// dialog steals focus for itself, which is not what we want for non-modal (viewing)
|
||||
getNodeByKey(noteEditor.getCurrentNoteId()).setFocus();
|
||||
treeUtils.getNodeByKey(noteEditor.getCurrentNoteId()).setFocus();
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -105,7 +105,7 @@ const encryption = (function() {
|
||||
}
|
||||
|
||||
for (const noteId of glob.allNoteIds) {
|
||||
const note = getNodeByKey(noteId);
|
||||
const note = treeUtils.getNodeByKey(noteId);
|
||||
|
||||
if (note.data.encryption > 0) {
|
||||
const title = decryptString(note.data.note_title);
|
||||
@@ -375,7 +375,7 @@ const encryption = (function() {
|
||||
function updateSubTreeRecursively(noteId, updateCallback, successCallback) {
|
||||
updateNoteSynchronously(noteId, updateCallback, successCallback);
|
||||
|
||||
const node = getNodeByKey(noteId);
|
||||
const node = treeUtils.getNodeByKey(noteId);
|
||||
if (!node || !node.getChildren()) {
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user