Merge pull request #50 from reduxionist/feature/do-not-skip-empty-files

Don't skip download if local file is empty.
This commit is contained in:
Footsiefat 2021-10-22 15:29:26 +13:00 committed by GitHub
commit 278e4d1bb3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -573,7 +573,7 @@ def download_track(track_id_str: str, extra_paths=""):
print("### SKIPPING:", song_name,
"(SONG IS UNAVAILABLE) ###")
else:
if os.path.isfile(filename) and SKIP_EXISTING_FILES:
if os.path.isfile(filename) and os.path.getsize(filename) and SKIP_EXISTING_FILES:
print("### SKIPPING:", song_name,
"(SONG ALREADY EXISTS) ###")
else: