diff --git a/yt_dlp/postprocessor/movefilesafterdownload.py b/yt_dlp/postprocessor/movefilesafterdownload.py index 590b3e314..ed544dc13 100644 --- a/yt_dlp/postprocessor/movefilesafterdownload.py +++ b/yt_dlp/postprocessor/movefilesafterdownload.py @@ -6,7 +6,7 @@ from ..utils import ( PostProcessingError, make_dir, - replace_extension + replace_extension, ) @@ -15,7 +15,7 @@ class MoveFilesAfterDownloadPP(PostProcessor): # for generating the output filename CHILD_KEYS = { 'thumbnails': 'thumbnail', - 'requested_subtitles': 'subtitle' + 'requested_subtitles': 'subtitle', } def __init__(self, downloader=None, downloaded=True): @@ -93,7 +93,7 @@ def run(self, info): if key not in info: continue - if isinstance(info[key], list) or isinstance(info[key], dict): + if isinstance(info[key], (dict, list)): iterable = info[key].values() if isinstance(info[key], dict) else info[key] for file_dict in iterable: diff --git a/yt_dlp/utils/_utils.py b/yt_dlp/utils/_utils.py index f1c2553e3..c3b741c0f 100644 --- a/yt_dlp/utils/_utils.py +++ b/yt_dlp/utils/_utils.py @@ -2106,7 +2106,7 @@ def check_executable(exe, args=[]): try: Popen.run([exe, *args], stdout=subprocess.PIPE, stderr=subprocess.PIPE) except OSError: - return False + return False return exe