mirror of
https://github.com/zadam/trilium.git
synced 2025-10-30 18:05:55 +01:00
small fixes
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
"use strict";
|
||||
|
||||
const noteCache = require('../../services/note_cache/note_cache');
|
||||
const log = require('../../services/log');
|
||||
|
||||
function getNotesAndBranchesAndAttributes(noteIds) {
|
||||
noteIds = new Set(noteIds);
|
||||
@@ -76,6 +77,11 @@ function getNotesAndBranchesAndAttributes(noteIds) {
|
||||
for (const branchId of collectedBranchIds) {
|
||||
const branch = noteCache.branches[branchId];
|
||||
|
||||
if (!branch) {
|
||||
log.error(`Could not find branch for branchId=${branchId}`);
|
||||
continue;
|
||||
}
|
||||
|
||||
branches.push({
|
||||
branchId: branch.branchId,
|
||||
noteId: branch.noteId,
|
||||
|
||||
Reference in New Issue
Block a user