Skip to content

Commit 50f9476

Browse files
telenordMylesBorins
telenord
authored andcommitted
http: http_common rename var to let and const
PR-URL: #30288 Reviewed-By: Сковорода Никита Андреевич <chalkerx@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
1 parent 9230fff commit 50f9476

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/_http_common.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ function parserOnHeadersComplete(versionMajor, versionMinor, headers, method,
9191
incoming.url = url;
9292
incoming.upgrade = upgrade;
9393

94-
var n = headers.length;
94+
let n = headers.length;
9595

9696
// If parser.maxHeaderPairs <= 0 assume that there's no limit.
9797
if (parser.maxHeaderPairs > 0)
@@ -120,8 +120,8 @@ function parserOnBody(b, start, len) {
120120

121121
// Pretend this was the result of a stream._read call.
122122
if (len > 0 && !stream._dumped) {
123-
var slice = b.slice(start, start + len);
124-
var ret = stream.push(slice);
123+
const slice = b.slice(start, start + len);
124+
const ret = stream.push(slice);
125125
if (!ret)
126126
readStop(this.socket);
127127
}

0 commit comments

Comments
 (0)