Skip to content

Commit caf734b

Browse files
Update to 1.0 of async
1 parent 97e0fb4 commit caf734b

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
"prepublishOnly": "yarn npm-run-all clean build"
3333
},
3434
"dependencies": {
35-
"@kristoferbaxter/async": "0.0.7",
35+
"@kristoferbaxter/async": "1.0.0",
3636
"bytes": "3.1.0",
3737
"fast-glob": "3.2.2",
3838
"kleur": "3.0.3",

src/compress.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ async function storeOriginalFileContents(context: Context, path: string): Promis
4848
*/
4949
export async function findItemsToCompress(context: Context, findDefaultSize: boolean): Promise<Array<CompressionItem>> {
5050
const toCompress: Array<CompressionItem> = [];
51-
for (const [path, sizeMapValue] of context.compressed) {
51+
await pool(Array.from(context.compressed), async ([path, sizeMapValue]) => {
5252
for (let iterator: number = 0; iterator < OrderedCompressionValues.length; iterator++) {
5353
const compression: Compression = OrderedCompressionValues[iterator] as Compression;
5454
const [size, maxSize] = sizeMapValue[iterator];
@@ -64,7 +64,7 @@ export async function findItemsToCompress(context: Context, findDefaultSize: boo
6464
});
6565
}
6666
}
67-
}
67+
});
6868

6969
return toCompress;
7070
}

0 commit comments

Comments
 (0)