Work around Chrome download limit

Closes #18775.
This commit is contained in:
Chocobo1
2023-04-15 14:51:27 +08:00
parent 5dcc14153f
commit d63e0ad78f
2 changed files with 11 additions and 1 deletions

View File

@@ -44,6 +44,7 @@ window.qBittorrent.Misc = (function() {
safeTrim: safeTrim,
toFixedPointString: toFixedPointString,
containsAllTerms: containsAllTerms,
sleep: sleep,
MAX_ETA: 8640000
};
};
@@ -218,6 +219,12 @@ window.qBittorrent.Misc = (function() {
});
};
const sleep = (ms) => {
return new Promise((resolve) => {
setTimeout(resolve, ms);
});
};
return exports();
})();