Skip to content

Commit

Permalink
doc: fix s/rstStream/close in example
Browse files Browse the repository at this point in the history
Backport-PR-URL: #20456
PR-URL: #18088
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
  • Loading branch information
jasnell authored and MylesBorins committed May 2, 2018
1 parent d9d0d0e commit 88babd5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion doc/api/http2.md
Expand Up @@ -1015,7 +1015,7 @@ const { NGHTTP2_CANCEL } = http2.constants;
const req = client.request({ ':path': '/' });

// Cancel the stream if there's no activity after 5 seconds
req.setTimeout(5000, () => req.rstStream(NGHTTP2_CANCEL));
req.setTimeout(5000, () => req.close(NGHTTP2_CANCEL));
```

#### http2stream.state
Expand Down

0 comments on commit 88babd5

Please sign in to comment.