Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorAdarsh Honawad <adarsh2397@gmail.com>2017-10-09 20:39:26 +0300
committerMichaƫl Zasso <targos@protonmail.com>2017-10-18 09:27:14 +0300
commit6670b35f23a179e87a2927ebda3531656f6c5a3d (patch)
tree8f0d1f3b045347a4b0679af77f98e8c37451f373 /doc
parent5a1867067cf5924b44faa84468303b928c98f5ea (diff)
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 <joyeec9h3@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Diffstat (limited to 'doc')
-rw-r--r--doc/api/http2.md4
1 files changed, 3 insertions, 1 deletions
diff --git a/doc/api/http2.md b/doc/api/http2.md
index 704e847908b..ca2ac644a0d 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);