Browse Source

doc: clarify error events in HTTP module documentation

Make it clear that error with throw if error listener is
not registered.

PR-URL: https://github.com/nodejs/node/pull/4275
Reviewed-By: Brian White <mscdex@mscdex.net>
Reviewed-By: James M Snell <jasnell@gmail.com>
v4.x
Lenny Markus 9 years ago
committed by Myles Borins
parent
commit
d87ad302ce
  1. 3
      doc/api/http.markdown

3
doc/api/http.markdown

@ -1063,7 +1063,8 @@ even if there is no data being written to the request body.
If any error is encountered during the request (be that with DNS resolution,
TCP level errors, or actual HTTP parse errors) an `'error'` event is emitted
on the returned request object.
on the returned request object. As with all `'error'` events, if no listeners
are registered the error will be thrown.
There are a few special headers that should be noted.

Loading…
Cancel
Save