From 47a282293f62813a88b4c4ba18bc5e5246a6515c Mon Sep 17 00:00:00 2001 From: James M Snell Date: Thu, 11 Jan 2018 10:05:15 -0800 Subject: [PATCH] doc: fix s/rstStream/close in example PR-URL: https://github.com/nodejs/node/pull/18088 Reviewed-By: Anna Henningsen Reviewed-By: Matteo Collina Reviewed-By: Luigi Pinca Reviewed-By: Daniel Bevenius --- doc/api/http2.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/api/http2.md b/doc/api/http2.md index c008a130915..f07c5fb0917 100644 --- a/doc/api/http2.md +++ b/doc/api/http2.md @@ -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