diff options
author | cjihrig <cjihrig@gmail.com> | 2020-05-09 04:25:55 +0300 |
---|---|---|
committer | cjihrig <cjihrig@gmail.com> | 2020-05-09 20:57:28 +0300 |
commit | cad76da198ff59e16d3439cbdb5793750c01f382 (patch) | |
tree | 8d4250f053cd127a490dffdfed669d0ced14a2b8 /doc/api/http.md | |
parent | ff6535a4331d611bf0d205ee23d88e100dce92b2 (diff) |
http: return this from ClientRequest#destroy()
This commit updates ClientRequest#destroy() to return `this`
for consistency with other writable streams.
PR-URL: https://github.com/nodejs/node/pull/32789
Reviewed-By: Robert Nagy <ronagy@icloud.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Michaƫl Zasso <targos@protonmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Diffstat (limited to 'doc/api/http.md')
-rw-r--r-- | doc/api/http.md | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/doc/api/http.md b/doc/api/http.md index 364978855ee..a6f73ee94f9 100644 --- a/doc/api/http.md +++ b/doc/api/http.md @@ -631,6 +631,11 @@ is finished. ### `request.destroy([error])` <!-- YAML added: v0.3.0 +changes: + - version: REPLACEME + pr-url: https://github.com/nodejs/node/pull/32789 + description: The function returns `this` for consistency with other Readable + streams. --> * `error` {Error} Optional, an error to emit with `'error'` event. |