Skip to content
Permalink
Browse files

http2: change var to let compact.js

PR-URL: #30392
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
  • Loading branch information
MariaEmma authored and MylesBorins committed Nov 12, 2019
1 parent 2f8dcef commit cb3e008c970d61007938aadc519b482b6c7d8346
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/internal/http2/compat.js
@@ -522,7 +522,7 @@ class Http2ServerResponse extends Stream {
addTrailers(headers) {
const keys = Object.keys(headers);
let key = '';
for (var i = 0; i < keys.length; i++) {
for (let i = 0; i < keys.length; i++) {
key = keys[i];
this.setTrailer(key, headers[key]);
}
@@ -606,7 +606,7 @@ class Http2ServerResponse extends Stream {
if (headers === undefined && typeof statusMessage === 'object')
headers = statusMessage;

var i;
let i;
if (Array.isArray(headers)) {
for (i = 0; i < headers.length; i++) {
const header = headers[i];

0 comments on commit cb3e008

Please sign in to comment.
You can’t perform that action at this time.