Skip non-integer youtube formats.

This commit is contained in:
auouymous 2021-07-07 01:59:41 -06:00
parent 79ef6aa8a2
commit 6e48992b31
1 changed files with 2 additions and 2 deletions

View File

@ -295,8 +295,8 @@ def get_real_download_url(url, allow_partial, preferred_fmt_ids=None):
fmt_id_url_map = dict(fmt_id_url_map)
for id in preferred_fmt_ids:
if re.search(r'(^best|\+)', str(id)):
# skip formats that contain 'best.*' or a + (136+140)
if not re.search(r'^[0-9]+$', str(id)):
# skip non-integer formats 'best', '136+140' or twitch '720p'
continue
id = int(id)
if id in formats_available: