mirror of
https://github.com/node-red/node-red.git
synced 2025-03-01 10:36:34 +00:00
Add error codes to api responses
This commit is contained in:
@@ -32,7 +32,7 @@ var settings = require("../settings");
|
||||
|
||||
var errorHandler = function(err,req,res,next) {
|
||||
console.log(err.stack);
|
||||
res.json(400,{message:err.toString()});
|
||||
res.json(400,{error:"unexpected_error", message:err.toString()});
|
||||
};
|
||||
|
||||
function init(adminApp,storage) {
|
||||
|
||||
Reference in New Issue
Block a user