Closed bmaupin closed 2 years ago
It looks like Node.js changed how it handles bad ports like that, which is why the example is not working with the current Node.js . It should still work, so it may just be a bug in the module now and not an issue with the docs.
I updated the README to use a commonly blocked port instead of an invalid port, which addresses your main issue. I will also follow up with a fix to forward thrown errors from Node.js connect to the callback as well.
The README gives this example on fatal errors, which I was trying to use to test generating a fatal error for an issue I'm having:
However the code to log
err.code
is never reached:Not only that, but the error that is thrown does not have
err.fatal
set. Using this code:I get this output:
Maybe it would be better to use a different example? Thanks!