1
0
Fork 0
mirror of https://codeberg.org/polarisfm/youtube-dl.git synced 2024-12-27 18:16:44 +00:00

Merge pull request #2274 from z00nx/master

[bliptv] Filter out SRT files
This commit is contained in:
Filippo Valsorda 2014-02-02 17:31:57 -08:00
commit 23fe495feb

View file

@ -78,8 +78,8 @@ class BlipTVIE(InfoExtractor):
upload_date = datetime.datetime.strptime(data['datestamp'], '%m-%d-%y %H:%M%p').strftime('%Y%m%d')
formats = []
if 'additionalMedia' in data:
for f in sorted(data['additionalMedia'], key=lambda f: int(f['media_height'])):
if not int(f['media_width']): # filter m3u8
for f in sorted(data['additionalMedia'], key=lambda f: int(0 if f['media_height'] is None else f['media_height'])):
if not int(0 if f['media_height'] is None else f['media_height']): # filter out m3u8 and srt files
continue
formats.append({
'url': f['url'],