1
0
mirror of https://github.com/l1ving/youtube-dl synced 2025-03-14 10:47:18 +08:00

[tele5] Fix extractor

This commit is contained in:
FliegendeWurst 2019-10-12 14:34:54 +02:00
parent c317b6163b
commit 5b2f81e500
No known key found for this signature in database
GPG Key ID: CA38E82B54B32A88
2 changed files with 12 additions and 5 deletions

View File

@ -364,6 +364,13 @@ class NexxIE(InfoExtractor):
'X-Request-Token': request_token,
})
# some videos have 'bumpers' (ads), the API returns a list in that case
if isinstance(video, list):
for v in video:
if compat_str(v['general']['ID']) == video_id:
# the bumpers have differing IDs
video = v
break
general = video['general']
title = general['title']

View File

@ -9,13 +9,13 @@ from ..compat import compat_urlparse
class Tele5IE(InfoExtractor):
_VALID_URL = r'https?://(?:www\.)?tele5\.de/(?:[^/]+/)*(?P<id>[^/?#&]+)'
_TESTS = [{
'url': 'https://www.tele5.de/mediathek/filme-online/videos?vid=1549416',
'url': 'https://www.tele5.de/sea-patrol/ganze-folge/lebenswege/',
'info_dict': {
'id': '1549416',
'id': '1630238',
'ext': 'mp4',
'upload_date': '20180814',
'timestamp': 1534290623,
'title': 'Pandorum',
'upload_date': '20190915',
'timestamp': 1568553091,
'title': 'Lebenswege'
},
'params': {
'skip_download': True,