diff --git a/apps/client/src/services/frontend_script_api_preact.ts b/apps/client/src/services/frontend_script_api_preact.ts index a8c6f52a3d..9ce7a52e72 100644 --- a/apps/client/src/services/frontend_script_api_preact.ts +++ b/apps/client/src/services/frontend_script_api_preact.ts @@ -1,4 +1,4 @@ -import { createContext,Fragment, h, VNode } from "preact"; +import { createContext, Fragment, h, VNode } from "preact"; import * as hooks from "preact/hooks"; import ActionButton from "../widgets/react/ActionButton"; diff --git a/apps/client/src/widgets/type_widgets/relation_map/api.ts b/apps/client/src/widgets/type_widgets/relation_map/api.ts index 10cacff6ed..dec79bfa8a 100644 --- a/apps/client/src/widgets/type_widgets/relation_map/api.ts +++ b/apps/client/src/widgets/type_widgets/relation_map/api.ts @@ -87,8 +87,8 @@ export default class RelationMapApi { ); if (exists) return false; - await server.remove(`notes/${relation.sourceNoteId}/relations/${relation.name}/to/${relation.targetNoteId}`); await server.put(`notes/${relation.sourceNoteId}/relations/${newName}/to/${relation.targetNoteId}`); + await server.remove(`notes/${relation.sourceNoteId}/relations/${relation.name}/to/${relation.targetNoteId}`); this.onDataChange(true); return true; } diff --git a/apps/server/src/services/backend_script_api.ts b/apps/server/src/services/backend_script_api.ts index d84b21fb39..3eff3cc355 100644 --- a/apps/server/src/services/backend_script_api.ts +++ b/apps/server/src/services/backend_script_api.ts @@ -621,7 +621,7 @@ function BackendScriptApi(this: Api, currentNote: BNote, apiParams: ApiParams) { } const parentNoteId = opts.isVisible ? "_lbVisibleLaunchers" : "_lbAvailableLaunchers"; - const noteId = `al_${ opts.id}`; + const noteId = `al_${opts.id}`; const launcherNote = becca.getNote(noteId) || @@ -699,7 +699,6 @@ function BackendScriptApi(this: Api, currentNote: BNote, apiParams: ApiParams) { return `!@#Function: ${p.toString()}`; } return p; - }); } };