1
0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2025-11-23 09:55:12 +00:00

[cleanup] Misc fixes and cleanup

Closes #3780, Closes #3853, Closes #3850
This commit is contained in:
pukkandan
2022-05-27 04:36:23 +05:30
parent 8246f8402b
commit 8a82af3511
16 changed files with 103 additions and 84 deletions

View File

@@ -1,4 +1,3 @@
from ..compat import compat_str
from ..utils import NO_DEFAULT, determine_protocol
@@ -91,7 +90,7 @@ def _get_suitable_downloader(info_dict, protocol, params, default):
info_dict['protocol'] = protocol
downloaders = params.get('external_downloader')
external_downloader = (
downloaders if isinstance(downloaders, compat_str) or downloaders is None
downloaders if isinstance(downloaders, str) or downloaders is None
else downloaders.get(shorten_protocol_name(protocol, True), downloaders.get('default')))
if external_downloader is None: