events: show inspected error in uncaught 'error' message
If there is no handler for `.emit('error', value)` and `value`
is not an `Error` object, we currently just call `.toString()`
on it.
Almost always, using `util.inspect()` provides better information
for diagnostic purposes, so prefer to use that instead.
Refs: https://github.com/nodejs/help/issues/1729
PR-URL: https://github.com/nodejs/node/pull/25621
Reviewed-By:
Luigi Pinca <luigipinca@gmail.com>
Reviewed-By:
Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By:
Matheus Marchini <mat@mmarchini.me>
parent
2b653996
Please register or sign in to comment