From 78cd5fedd560eef8a17d0a63d32515ef2349f671 Mon Sep 17 00:00:00 2001 From: Matteo Collina Date: Mon, 24 Jul 2017 19:04:53 +0100 Subject: [PATCH] http2: make writeHead behave like HTTP/1. PR-URL: https://github.com/nodejs/node/pull/14239 Reviewed-By: Anna Henningsen Reviewed-By: Colin Ihrig Reviewed-By: Matteo Collina --- doc/api/http2.md | 2 +- lib/internal/http2/compat.js | 43 +++++++------------ .../test-http2-compat-serverresponse-end.js | 1 - ...ttp2-compat-serverresponse-flushheaders.js | 11 ++++- ...t-http2-compat-serverresponse-writehead.js | 6 ++- 5 files changed, 29 insertions(+), 34 deletions(-) diff --git a/doc/api/http2.md b/doc/api/http2.md index 6f106c69c1..bf2f6a3c52 100755 --- a/doc/api/http2.md +++ b/doc/api/http2.md @@ -2402,7 +2402,7 @@ buffer. Returns `false` if all or part of the data was queued in user memory. added: REPLACEME --> -Does nothing. Added for parity with [HTTP/1](). +Throws an error as the `'continue'` flow is not current implemented. Added for parity with [HTTP/1](). ### response.writeHead(statusCode[, statusMessage][, headers])