Skip to content

Commit

Permalink
fix: put back original lines of code
Browse files Browse the repository at this point in the history
  • Loading branch information
coltonehrman committed Aug 11, 2024
1 parent 0298848 commit 0812d25
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -176,8 +176,8 @@ function getErrorMessage (err, status, env) {
// use util.format to get native Error print
msg = util.format(err)

// fallback to err.toString() when possible
if (!msg && typeof err.toString === 'function') {
// fallback to err.toString() when possible
msg = err.toString()
}
}
Expand Down
2 changes: 1 addition & 1 deletion test/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -578,7 +578,7 @@ describe('finalhandler(req, res)', function () {
})
})

describe.only('Errors with cause', function () {
describe('Errors with cause', function () {
it('should return Error message with 1 level cause trace', function (done) {
var err = new Error('foo', { cause: new Error('bar') })

Expand Down

0 comments on commit 0812d25

Please sign in to comment.