How would I handle an error when a client disconnects? #49
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
I have a node.js server that interfaces with a website, and when I close a tab the server crashes due to an "Unhandled 'error' event"
I assume I need to add an error handler after .listen() but I cant figure out how to do it.
I know this is a noob question but I'm still learning about websockets.
conn.on("error", function (code, reason) {
console.log("error msg")
});