Skip to content

Commit

Permalink
lib: this commit uses let instead of var for util.js & warning.js
Browse files Browse the repository at this point in the history
  • Loading branch information
19shubham11 committed Nov 12, 2019
1 parent cc6f99d commit 0409a75
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/internal/process/warning.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ function onWarning(warning) {
if (isDeprecation && process.noDeprecation) return;
const trace = process.traceProcessWarnings ||
(isDeprecation && process.traceDeprecation);
var msg = `(${process.release.name}:${process.pid}) `;
let msg = `(${process.release.name}:${process.pid}) `;
if (warning.code)
msg += `[${warning.code}] `;
if (trace && warning.stack) {
Expand Down
4 changes: 2 additions & 2 deletions lib/internal/util.js
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ function emitExperimentalWarning(feature) {

function filterDuplicateStrings(items, low) {
const map = new Map();
for (var i = 0; i < items.length; i++) {
for (let i = 0; i < items.length; i++) {
const item = items[i];
const key = item.toLowerCase();
if (low) {
Expand Down Expand Up @@ -281,7 +281,7 @@ function promisify(original) {
}
if (argumentNames !== undefined && values.length > 1) {
const obj = {};
for (var i = 0; i < argumentNames.length; i++)
for (let i = 0; i < argumentNames.length; i++)
obj[argumentNames[i]] = values[i];
resolve(obj);
} else {
Expand Down

0 comments on commit 0409a75

Please sign in to comment.