[ytdl] update 'parse_bytes' location (#3256)
https://github.com/yt-dlp/yt-dlp/commit/64c464a
This commit is contained in:
@@ -73,7 +73,11 @@ def parse_command_line(module, argv):
|
|||||||
|
|
||||||
ytdlp = (module.__name__ == "yt_dlp")
|
ytdlp = (module.__name__ == "yt_dlp")
|
||||||
std_headers = module.std_headers
|
std_headers = module.std_headers
|
||||||
parse_bytes = module.FileDownloader.parse_bytes
|
|
||||||
|
try:
|
||||||
|
parse_bytes = module.parse_bytes
|
||||||
|
except AttributeError:
|
||||||
|
parse_bytes = module.FileDownloader.parse_bytes
|
||||||
|
|
||||||
# HTTP headers
|
# HTTP headers
|
||||||
if opts.user_agent is not None:
|
if opts.user_agent is not None:
|
||||||
|
|||||||
Reference in New Issue
Block a user