From 5ee48c68b88c6d273fc6ed6500ff5202655ab9f1 Mon Sep 17 00:00:00 2001 From: zadam Date: Fri, 27 Mar 2020 07:56:10 +0100 Subject: [PATCH] Updated Custom request handler (markdown) --- Custom-request-handler.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Custom-request-handler.md b/Custom-request-handler.md index e439406..f62aeaa 100644 --- a/Custom-request-handler.md +++ b/Custom-request-handler.md @@ -10,8 +10,9 @@ const {req, res} = api; const {secret, title, content} = req.body; if (req.method == 'POST' && secret === 'secret-password') { - // notes must be saved somewhere - under a parent. This is specified by a relation to the "target note" - // alternetively you can just use constant noteId for simplicity (get that from "Note Info" dialog) + // notes must be saved somewhere in the tree hierarchy specified by a parent note. + // This is defined by a relation from this code note to the "target" parent note + // alternetively you can just use constant noteId for simplicity (get that from "Note Info" dialog of the desired parent note) const targetParentNoteId = await api.currentNote.getRelationValue('targetNote'); await api.createTextNote(targetParentNoteId, title, content);