summaryrefslogtreecommitdiff
path: root/lib/web
diff options
context:
space:
mode:
authorErik Michelson2021-03-29 23:07:11 +0200
committerErik Michelson2021-03-29 23:07:11 +0200
commitdcea082286ce5c41e50f70820c065c677a176fc7 (patch)
tree5fde7fe01a3ecbc9593c9ee6f679627f28a95ef1 /lib/web
parent124b06425214921c30a88e44a139b1cc8ca15b45 (diff)
Add better logging messages
Signed-off-by: Erik Michelson <opensource@erik.michelson.eu>
Diffstat (limited to 'lib/web')
-rw-r--r--lib/web/note/util.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/web/note/util.js b/lib/web/note/util.js
index dbca5d8e..5df1e820 100644
--- a/lib/web/note/util.js
+++ b/lib/web/note/util.js
@@ -70,7 +70,7 @@ exports.newNote = async function (req, res, body) {
return errors.errorConflict(res)
}
} catch (err) {
- logger.error(err)
+ logger.error('Error while checking for possible duplicate: ' + err)
return errors.errorInternalError(res)
}
}
@@ -82,7 +82,7 @@ exports.newNote = async function (req, res, body) {
}).then(function (note) {
return res.redirect(config.serverURL + '/' + (note.alias ? note.alias : models.Note.encodeNoteId(note.id)))
}).catch(function (err) {
- logger.error(err)
+ logger.error('Note could not be created: ' + err)
return errors.errorInternalError(res)
})
}