pass debug to promise-retry

This commit is contained in:
Girish Ramakrishnan
2021-12-07 11:18:26 -08:00
parent ae0e572593
commit 013f5d359d
6 changed files with 14 additions and 19 deletions
+2 -3
View File
@@ -38,9 +38,8 @@ async function downloadUrl(url, file) {
safe.fs.unlinkSync(file);
let retryCount = 0;
await promiseRetry({ times: 10, interval: 5000 }, async function () {
debug(`Downloading ${url} to ${file}. Try ${++retryCount}`);
await promiseRetry({ times: 10, interval: 5000, debug }, async function () {
debug(`Downloading ${url} to ${file}`);
const args = `-s --fail ${url} -o ${file}`;