method
bun.WebSocketHandler.error
): void | Promise<void>;
Called when one of the other handlers throws. Without it, the error is an uncaught exception.
Not called when an async handler rejects. That's an unhandled rejection.
@param error
The value that was thrown
@param ws
The websocket whose handler threw