From 6670b35f23a179e87a2927ebda3531656f6c5a3d Mon Sep 17 00:00:00 2001 From: Adarsh Honawad Date: Mon, 9 Oct 2017 23:09:26 +0530 Subject: [PATCH] doc: remove undefined reference variable Remove undefined reference variable 'common' from http2 API PR-URL: https://github.com/nodejs/node/pull/16106 Fixes: https://github.com/nodejs/node/issues/16068 Reviewed-By: Joyee Cheung Reviewed-By: James M Snell --- doc/api/http2.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/doc/api/http2.md b/doc/api/http2.md index 704e847908ba15..ca2ac644a0d4bc 100644 --- a/doc/api/http2.md +++ b/doc/api/http2.md @@ -1902,7 +1902,9 @@ const req = client.request({ ':authority': `localhost:${port}` }); -req.on('response', common.mustCall()); +req.on('response', (headers) => { + console.log(headers[http2.constants.HTTP2_HEADER_STATUS]); +}); let data = ''; req.setEncoding('utf8'); req.on('data', (chunk) => data += chunk);