Second pass converting for index based looping to for-of loops

More manual conversion of index based for loops to for-of loops
This commit is contained in:
Matt Bierner
2019-01-03 20:19:49 -08:00
parent 137dbe92bb
commit c109d319fe
59 changed files with 174 additions and 200 deletions

View File

@@ -87,8 +87,8 @@ export class PackageJSONContribution implements IJSONContribution {
const obj = JSON.parse(success.responseText);
if (obj && Array.isArray(obj.rows)) {
const results = <{ key: string[]; }[]>obj.rows;
for (let i = 0; i < results.length; i++) {
const keys = results[i].key;
for (const result of results) {
const keys = result.key;
if (Array.isArray(keys) && keys.length > 0) {
const name = keys[0];
const insertText = new SnippetString().appendText(JSON.stringify(name));