summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorexislow <exislow@users.noreply.github.com>2024-04-03 06:11:51 +0200
committerGitHub <noreply@github.com>2024-04-03 06:11:51 +0200
commitd7e4a888b7828138567c90c3cd10208649fcc60e (patch)
tree5abbfafe7027bfd8a87d84512a7a61e0a7912ff5
parent48d4293a7088ce8dd569541542d2cfd19fdf2d50 (diff)
parentff16fce066f61edd26c2e6db5e7405398ab2775c (diff)
downloadtidal-dl-ng-d7e4a888b7828138567c90c3cd10208649fcc60e.tar.gz
Merge pull request #78 from exislow/77-bug-excessive-api-requests-caused-by-if-file-exist-skip-download-check-during-playlist-download
✨ Download delay enabled for skipped tracks.
-rw-r--r--tidal_dl_ng/download.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/tidal_dl_ng/download.py b/tidal_dl_ng/download.py
index 4ad3af2..a8545c7 100644
--- a/tidal_dl_ng/download.py
+++ b/tidal_dl_ng/download.py
@@ -255,9 +255,9 @@ class Download:
status_download: bool = not file_exists
- # If a file was downloaded and the download delay is enabled, wait until the next download.
- # Only use this, if you have a list of several Track items. Do not use this for list items.
- if download_delay and status_download:
+ # Whether a file was downloaded or skipped and the download delay is enabled, wait until the next download.
+ # Only use this, if you have a list of several Track items.
+ if download_delay:
time_sleep: float = round(random.SystemRandom().uniform(2, 5), 1)
self.fn_logger.debug(f"Next download will start in {time_sleep} seconds.")