code should not rely on fixed branch IDs since they can change after move

This commit is contained in:
zadam
2022-12-23 20:40:58 +01:00
parent e5e0add1a2
commit 5c4db266a4
11 changed files with 29 additions and 35 deletions

View File

@@ -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;