From a84e10eba0f79608711285f673c4103940e00c2c 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 d7691618b46..6e9c1d6b8a2 100644 --- a/doc/api/http2.md +++ b/doc/api/http2.md @@ -1899,7 +1899,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);