mirror of
https://github.com/nodejs/node.git
synced 2026-11-09 15:11:11 -05:00
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>
This commit is contained in:
1 parent
c6efd535e4
commit
9538fd02e5
1 file changed
+2
-1
@@ -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.
|
||||
|
||||
|
||||
Reference in new issue
Block a user