mirror of
https://github.com/nodejs/node.git
synced 2024-12-01 16:10:02 +01:00
doc: add information for IncomingMessage.destroy()
Add documentation for `http.IncomingMessage.prototype.destroy()`. PR-URL: https://github.com/nodejs/node/pull/7237 Fixes: https://github.com/nodejs/node/issues/4226 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: cjihrig - Colin Ihrig <cjihrig@gmail.com>
This commit is contained in:
parent
197a465280
commit
4f2aec307e
@ -910,6 +910,14 @@ following additional events, methods, and properties.
|
||||
Indicates that the underlying connection was closed.
|
||||
Just like `'end'`, this event occurs only once per response.
|
||||
|
||||
### message.destroy([error])
|
||||
|
||||
* `error` {Error}
|
||||
|
||||
Calls `destroy()` on the socket that received the `IncomingMessage`. If `error`
|
||||
is provided, an `'error'` event is emitted and `error` is passed as an argument
|
||||
to any listeners on the event.
|
||||
|
||||
### message.headers
|
||||
|
||||
The request/response headers object.
|
||||
|
Loading…
Reference in New Issue
Block a user