fix test noise

TypeError: Cannot read property 'name' of undefined
    at log (/home/travis/build/rlidwka/sinopia/lib/middleware.js:185:32)
This commit is contained in:
Alex Kocharin 2015-01-26 14:00:37 +03:00
parent f558c78d32
commit 5b5f56f51c
1 changed files with 1 additions and 1 deletions

View File

@ -182,7 +182,7 @@ module.exports.log = function(req, res, next) {
req.log.warn({ req.log.warn({
request : { method: req.method, url: req.url }, request : { method: req.method, url: req.url },
level : 35, // http level : 35, // http
user : req.remote_user.name, user : req.remote_user && req.remote_user.name,
status : res.statusCode, status : res.statusCode,
error : res._sinopia_error, error : res._sinopia_error,
bytes : { bytes : {