mirror of
https://github.com/zadam/trilium.git
synced 2025-10-27 16:26:31 +01:00
code should not rely on fixed branch IDs since they can change after move
This commit is contained in:
@@ -493,12 +493,12 @@ function BackendScriptApi(currentNote, apiParams) {
|
||||
if (opts.type === 'customWidget' && !opts.widgetNoteId) { throw new Error("widgetNoteId is mandatory for launchers of type 'customWidget'"); }
|
||||
|
||||
const parentNoteId = !!opts.isVisible ? '_lbVisibleLaunchers' : '_lbAvailableLaunchers';
|
||||
const actualId = 'al_' + opts.id;
|
||||
const noteId = 'al_' + opts.id;
|
||||
|
||||
const launcherNote =
|
||||
becca.getNote(opts.id) ||
|
||||
specialNotesService.createLauncher({
|
||||
id: actualId,
|
||||
noteId: noteId,
|
||||
parentNoteId: parentNoteId,
|
||||
launcherType: opts.type,
|
||||
}).note;
|
||||
|
||||
Reference in New Issue
Block a user