Skip to content

Commit

Permalink
Return exception message as response on error
Browse files Browse the repository at this point in the history
  • Loading branch information
Vinarnt committed Aug 23, 2021
1 parent 51b4c97 commit bd14e57
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
/node_modules/
.vscode/launch.json
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ app.all('*', function (req, res) {
console.log('')

res.writeHead(400, { 'Content-Type': 'text/plain' })
res.end()
res.end(ex.message)
}
})

Expand Down

0 comments on commit bd14e57

Please sign in to comment.