aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authordavidmarkclements <huperekchuno@googlemail.com>2018-04-04 21:11:27 +0200
committerJames M Snell <jasnell@gmail.com>2018-04-14 13:18:21 -0700
commitcc7bef9eed6641aa0e821139b9d5227f4ae81496 (patch)
tree7c64caed3359f262040f81d79facd86a3d9af528 /lib
parente76831be0ca92585f2e4a3caf26875c6963b6019 (diff)
downloadandroid-node-v8-cc7bef9eed6641aa0e821139b9d5227f4ae81496.tar.gz
android-node-v8-cc7bef9eed6641aa0e821139b9d5227f4ae81496.tar.bz2
android-node-v8-cc7bef9eed6641aa0e821139b9d5227f4ae81496.zip
errors: alter ERR_HTTP2_PSEUDOHEADER_NOT_ALLOWED
changes the base instance for ERR_HTTP2_PSEUDOHEADER_NOT_ALLOWED from Error to TypeError as a more accurate representation of the error.. PR-URL: https://github.com/nodejs/node/pull/19958 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Yuta Hiroto <hello@hiroppy.me> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/internal/errors.js4
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/internal/errors.js b/lib/internal/errors.js
index c2a0f08620..35c3fb74b0 100644
--- a/lib/internal/errors.js
+++ b/lib/internal/errors.js
@@ -826,10 +826,8 @@ E('ERR_HTTP2_PAYLOAD_FORBIDDEN',
'Responses with %s status must not have a payload', Error);
E('ERR_HTTP2_PING_CANCEL', 'HTTP2 ping cancelled', Error);
E('ERR_HTTP2_PING_LENGTH', 'HTTP2 ping payload must be 8 bytes', RangeError);
-
-// This should probably be a `TypeError`.
E('ERR_HTTP2_PSEUDOHEADER_NOT_ALLOWED',
- 'Cannot set HTTP/2 pseudo-headers', Error);
+ 'Cannot set HTTP/2 pseudo-headers', TypeError);
E('ERR_HTTP2_PUSH_DISABLED', 'HTTP/2 client has disabled push streams', Error);
E('ERR_HTTP2_SEND_FILE', 'Directories cannot be sent', Error);
E('ERR_HTTP2_SEND_FILE_NOSEEK',