mirror of
https://github.com/Wojtek242/qobuz-dl.git
synced 2024-11-22 11:05:25 +01:00
Fix problem with booleans from configparser
This commit is contained in:
parent
f370b5c0b0
commit
df578d1d02
@ -81,12 +81,12 @@ def main():
|
||||
default_folder = config["DEFAULT"]["default_folder"]
|
||||
default_limit = config["DEFAULT"]["default_limit"]
|
||||
default_quality = config["DEFAULT"]["default_quality"]
|
||||
no_m3u = config["DEFAULT"]["no_m3u"]
|
||||
albums_only = config["DEFAULT"]["albums_only"]
|
||||
no_fallback = config["DEFAULT"]["no_fallback"]
|
||||
og_cover = config["DEFAULT"]["og_cover"]
|
||||
embed_art = config["DEFAULT"]["embed_art"]
|
||||
no_cover = config["DEFAULT"]["no_cover"]
|
||||
no_m3u = config.getboolean("DEFAULT", "no_m3u")
|
||||
albums_only = config.getboolean("DEFAULT", "albums_only")
|
||||
no_fallback = config.getboolean("DEFAULT", "no_fallback")
|
||||
og_cover = config.getboolean("DEFAULT", "og_cover")
|
||||
embed_art = config.getboolean("DEFAULT", "embed_art")
|
||||
no_cover = config.getboolean("DEFAULT", "no_cover")
|
||||
app_id = config["DEFAULT"]["app_id"]
|
||||
secrets = [
|
||||
secret for secret in config["DEFAULT"]["secrets"].split(",") if secret
|
||||
|
@ -221,8 +221,13 @@ def download_id_by_type(
|
||||
sanitized_title = sanitize_filename("{} - {} [{}] [{}]".format(*dirT))
|
||||
dirn = os.path.join(path, sanitized_title)
|
||||
os.makedirs(dirn, exist_ok=True)
|
||||
if not no_cover:
|
||||
|
||||
if no_cover:
|
||||
logger.info(f"{OFF}Skipping cover")
|
||||
else:
|
||||
get_extra(meta["image"]["large"], dirn, og_quality=cover_og_quality)
|
||||
|
||||
|
||||
if "goodies" in meta:
|
||||
try:
|
||||
get_extra(meta["goodies"][0]["url"], dirn, "booklet.pdf")
|
||||
@ -278,7 +283,9 @@ def download_id_by_type(
|
||||
sanitized_title = sanitize_filename("{} - {} [{}] [{}]".format(*dirT))
|
||||
dirn = os.path.join(path, sanitized_title)
|
||||
os.makedirs(dirn, exist_ok=True)
|
||||
if not no_cover:
|
||||
if no_cover:
|
||||
logger.info(f"{OFF}Skipping cover")
|
||||
else:
|
||||
get_extra(
|
||||
meta["album"]["image"]["large"], dirn, og_quality=cover_og_quality
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user