judge: pass 'this' param to download (strict mode)

pull/169/head
undefined 3 years ago
parent d0592eac5b
commit 7006457001

@ -1,7 +1,7 @@
{
"name": "@hydrooj/hydrojudge",
"bin": "bin/hydrojudge.js",
"version": "2.9.4",
"version": "2.9.5",
"main": "package.json",
"author": "undefined <i@undefined.moe>",
"repository": "https://github.com/hydro-dev/Hydro.git",

@ -233,7 +233,7 @@ export default class Hydro {
const tasks = [];
const queue = new PQueue({ concurrency: 10 });
for (const name in res.data.links) {
tasks.push(queue.add(() => download(name)));
tasks.push(queue.add(() => download.call(this, name)));
}
queue.start();
await Promise.all(tasks);

Loading…
Cancel
Save