Fix little bug in length limit
Signed-off-by: Sheogorath <sheogorath@shivering-isles.com>
This commit is contained in:
@@ -151,7 +151,7 @@ function newNote (req, res, next) {
|
|||||||
var body = ''
|
var body = ''
|
||||||
if (req.body && req.body.length > config.documentMaxLength) {
|
if (req.body && req.body.length > config.documentMaxLength) {
|
||||||
return response.errorTooLong(res)
|
return response.errorTooLong(res)
|
||||||
} else {
|
} else if (req.body) {
|
||||||
body = req.body
|
body = req.body
|
||||||
}
|
}
|
||||||
body = body.replace(/[\r]/g, '')
|
body = body.replace(/[\r]/g, '')
|
||||||
|
|||||||
Reference in New Issue
Block a user