working on more informative log files

parent 33eafeb1
Showing with 6 additions and 4 deletions
...@@ -59,10 +59,12 @@ module.exports.http = { ...@@ -59,10 +59,12 @@ module.exports.http = {
* * * *
****************************************************************************/ ****************************************************************************/
myRequestLogger: function (req, res, next) { myRequestLogger: function (req, res, next) {
req._sails.log.info(req.method, req.url, res.statusCode, req.allParams()); res.on("finish", function() {
return next(); sails..info(req.method, req.url, res.statusCode, req.allParams());
}, });
return next();
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment