mirror of
https://github.com/l1ving/youtube-dl
synced 2025-02-03 11:22:54 +08:00
Allow formats with labels that don't match regex ([0-9]+)p
This commit is contained in:
parent
1ff963a230
commit
51285bd7c7
@ -47,6 +47,7 @@ class PietsmietIE(OnceIE):
|
|||||||
http_video = data_video['sources'][1]
|
http_video = data_video['sources'][1]
|
||||||
|
|
||||||
label = http_video.get('label')
|
label = http_video.get('label')
|
||||||
|
format_height = 0
|
||||||
|
|
||||||
if label:
|
if label:
|
||||||
# Calculate resolution for HTTP format but should always be 1280x720
|
# Calculate resolution for HTTP format but should always be 1280x720
|
||||||
@ -55,7 +56,7 @@ class PietsmietIE(OnceIE):
|
|||||||
default=720, fatal=False)
|
default=720, fatal=False)
|
||||||
format_height = int_or_none(format_height_raw)
|
format_height = int_or_none(format_height_raw)
|
||||||
|
|
||||||
if format_height:
|
if format_height > 0:
|
||||||
format_width = float(format_height) * (16 / 9)
|
format_width = float(format_height) * (16 / 9)
|
||||||
|
|
||||||
formats.append({
|
formats.append({
|
||||||
|
Loading…
Reference in New Issue
Block a user