From 4d110aa143771ece9e8858370b88d7dfd7b5e883 Mon Sep 17 00:00:00 2001 From: zadam Date: Mon, 5 Apr 2021 22:37:12 +0200 Subject: [PATCH] updated render note help --- src/public/app/widgets/type_widgets/render.js | 2 +- src/services/auth.js | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/public/app/widgets/type_widgets/render.js b/src/public/app/widgets/type_widgets/render.js index 98c433381..ceb680261 100644 --- a/src/public/app/widgets/type_widgets/render.js +++ b/src/public/app/widgets/type_widgets/render.js @@ -6,7 +6,7 @@ const TPL = `

This help note is shown because this note of type Render HTML doesn't have required relation to function properly.

-

Render HTML note type is used for scripting. In short, you have a HTML code note (optionally with some JavaScript) and this note will render it. To make it work, you need to define a relation (in Attributes dialog) called "renderNote" pointing to the HTML note to render. Once that's defined you can click on the "play" button to render.

+

Render HTML note type is used for scripting. In short, you have a HTML code note (optionally with some JavaScript) and this note will render it. To make it work, you need to define a relation called "renderNote" pointing to the HTML note to render.

diff --git a/src/services/auth.js b/src/services/auth.js index e5ec51980..b6ec61311 100644 --- a/src/services/auth.js +++ b/src/services/auth.js @@ -26,7 +26,7 @@ function checkAuth(req, res, next) { // currently we're doing that for file upload because handling form data seems to be difficult function checkApiAuthOrElectron(req, res, next) { if (!req.session.loggedIn && !utils.isElectron() && !noAuthentication) { - reject(req, res, "Not authorized"); + reject(req, res, "Logged in session not found"); } else { next(); @@ -35,7 +35,7 @@ function checkApiAuthOrElectron(req, res, next) { function checkApiAuth(req, res, next) { if (!req.session.loggedIn && !noAuthentication) { - reject(req, res, "Not authorized"); + reject(req, res, "Logged in session not found"); } else { next(); @@ -64,7 +64,7 @@ function checkToken(req, res, next) { const token = req.headers.authorization; if (sql.getValue("SELECT COUNT(*) FROM api_tokens WHERE isDeleted = 0 AND token = ?", [token]) === 0) { - reject(req, res, "Not authorized"); + reject(req, res, "Token not found"); } else { next();