Added logic in case throwErr() is not given a req

master
Keith Irwin 2017-12-19 06:39:15 +00:00
parent dcf522fcb5
commit 4bcf4da286
No known key found for this signature in database
GPG Key ID: 378933C743E2BBC0
1 changed files with 1 additions and 1 deletions

View File

@ -7,7 +7,7 @@ module.exports = {
// Throw error
throwErr: (err, req=null) => {
debug(`throwErr(${err.message},${req.url})`)
debug(`throwErr(${err.message},${req?req.url:'null'})`)
console.error(err.stack)
if (req) {
if (env.mode==='production') {