Skip to content

Commit

Permalink
doc: fix http2stream.pushStream error doc
Browse files Browse the repository at this point in the history
The old error code `ERR_HTTP2_STREAM_CLOSED` was removed in commit
0babd18 (pull request #17406), and the
testcase for http2stream.pushStream was changed accordingly, but the
documentation change was overlooked.

This commit fixes it and aligns the documentation with the testcase.

This is a part of the fixes hinted by #21470, which includes some tests
for error codes usage and documentation and enforces a stricter format.

Refs: #21470
Refs: #17406
PR-URL: #21487
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Vse Mozhet Byt <vsemozhetbyt@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
  • Loading branch information
ChALkeR authored and targos committed Jul 12, 2018
1 parent 6e1917a commit 51db88b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion doc/api/http2.md
Original file line number Diff line number Diff line change
Expand Up @@ -3143,7 +3143,7 @@ added: v8.4.0
Call [`http2stream.pushStream()`][] with the given headers, and wraps the
given newly created [`Http2Stream`] on `Http2ServerResponse`.

The callback will be called with an error with code `ERR_HTTP2_STREAM_CLOSED`
The callback will be called with an error with code `ERR_HTTP2_INVALID_STREAM`
if the stream is closed.

## Collecting HTTP/2 Performance Metrics
Expand Down

0 comments on commit 51db88b

Please sign in to comment.