Skip to content

Commit 890baa0

Browse files
JacksonTianJulien Gilli
authored and
Julien Gilli
committed
doc: add details for http res/req end callback
Add documentation for the callback parameter of http.ClientRequest's and http.ServerResponse's end methods. Signed-off-by: Julien Gilli <[email protected]>
1 parent 9158666 commit 890baa0

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

doc/api/http.markdown

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -444,6 +444,8 @@ response.
444444
If `data` is specified, it is equivalent to calling
445445
`response.write(data, encoding)` followed by `response.end(callback)`.
446446

447+
If `callback` is specified, it will be called when the response stream
448+
is finished.
447449

448450
## http.request(options[, callback])
449451

@@ -890,6 +892,9 @@ chunked, this will send the terminating `'0\r\n\r\n'`.
890892
If `data` is specified, it is equivalent to calling
891893
`request.write(data, encoding)` followed by `request.end(callback)`.
892894

895+
If `callback` is specified, it will be called when the request stream
896+
is finished.
897+
893898
### request.abort()
894899

895900
Aborts a request. (New since v0.3.8.)

0 commit comments

Comments
 (0)