1
0
Fork 0
mirror of https://codeberg.org/polarisfm/youtube-dl.git synced 2024-12-27 01:56:52 +00:00

[liveleak] Ensure height is int (closes #13313)

This commit is contained in:
Sergey M․ 2017-06-08 22:54:30 +07:00
parent c996943418
commit 931adf8cc1
No known key found for this signature in database
GPG key ID: 2C393E0F18A9236D

View file

@ -115,8 +115,9 @@ class LiveLeakIE(InfoExtractor):
for a_format in info_dict['formats']:
if not a_format.get('height'):
a_format['height'] = self._search_regex(
r'([0-9]+)p\.mp4', a_format['url'], 'height label', default=None)
a_format['height'] = int_or_none(self._search_regex(
r'([0-9]+)p\.mp4', a_format['url'], 'height label',
default=None))
self._sort_formats(info_dict['formats'])