Skip to content

Commit d3605cc

Browse files
mbelskyRachel Macfarlane
authored andcommitted
Use const instead of let
1 parent a22b7c6 commit d3605cc

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

src/bootstrap.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ exports.setupNLS = function () {
203203
const bundles = Object.create(null);
204204

205205
nlsConfig.loadBundle = function (bundle, language, cb) {
206-
let result = bundles[bundle];
206+
const result = bundles[bundle];
207207
if (result) {
208208
cb(undefined, result);
209209

@@ -212,7 +212,7 @@ exports.setupNLS = function () {
212212

213213
const bundleFile = path.join(nlsConfig._resolvedLanguagePackCoreLocation, bundle.replace(/\//g, '!') + '.nls.json');
214214
exports.readFile(bundleFile).then(function (content) {
215-
let json = JSON.parse(content);
215+
const json = JSON.parse(content);
216216
bundles[bundle] = json;
217217

218218
cb(undefined, json);
@@ -301,4 +301,4 @@ exports.avoidMonkeyPatchFromAppInsights = function () {
301301
process.env['APPLICATION_INSIGHTS_NO_DIAGNOSTIC_CHANNEL'] = true; // Skip monkey patching of 3rd party modules by appinsights
302302
global['diagnosticsSource'] = {}; // Prevents diagnostic channel (which patches "require") from initializing entirely
303303
};
304-
//#endregion
304+
//#endregion

src/vs/base/node/languagePacks.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -268,10 +268,10 @@ function factory(nodeRequire, path, fs, perf) {
268268
const packData = JSON.parse(values[1]).contents;
269269
const bundles = Object.keys(metadata.bundles);
270270
const writes = [];
271-
for (let bundle of bundles) {
271+
for (const bundle of bundles) {
272272
const modules = metadata.bundles[bundle];
273273
const target = Object.create(null);
274-
for (let module of modules) {
274+
for (const module of modules) {
275275
const keys = metadata.keys[module];
276276
const defaultMessages = metadata.messages[module];
277277
const translations = packData[module];
@@ -329,4 +329,4 @@ if (typeof define === 'function') {
329329
module.exports = factory(require, path, fs, perf);
330330
} else {
331331
throw new Error('Unknown context');
332-
}
332+
}

0 commit comments

Comments
 (0)