aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl/extractor/ard.py
diff options
context:
space:
mode:
authorsprhawk <465558+sprhawk@users.noreply.github.com>2017-12-26 22:27:26 +0800
committersprhawk <465558+sprhawk@users.noreply.github.com>2017-12-26 22:27:26 +0800
commitc33de004e13da11f1ae3cad7310b36500cfb9d28 (patch)
treec742e448af6c126eca4b259c85f83177aec54847 /youtube_dl/extractor/ard.py
parent42a1012c7767306626c5358a18ad3e86417bd7b7 (diff)
parentdb145ee54a57f5ccc89639de8c589eb111a91b19 (diff)
Merge branch 'master' of github.com:rg3/youtube-dl into weibo
Diffstat (limited to 'youtube_dl/extractor/ard.py')
-rw-r--r--youtube_dl/extractor/ard.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/youtube_dl/extractor/ard.py b/youtube_dl/extractor/ard.py
index 915f8862e..ef73d5a93 100644
--- a/youtube_dl/extractor/ard.py
+++ b/youtube_dl/extractor/ard.py
@@ -5,6 +5,7 @@ import re
from .common import InfoExtractor
from .generic import GenericIE
+from ..compat import compat_str
from ..utils import (
determine_ext,
ExtractorError,
@@ -126,6 +127,8 @@ class ARDMediathekIE(InfoExtractor):
quality = stream.get('_quality')
server = stream.get('_server')
for stream_url in stream_urls:
+ if not isinstance(stream_url, compat_str) or '//' not in stream_url:
+ continue
ext = determine_ext(stream_url)
if quality != 'auto' and ext in ('f4m', 'm3u8'):
continue
@@ -146,13 +149,11 @@ class ARDMediathekIE(InfoExtractor):
'play_path': stream_url,
'format_id': 'a%s-rtmp-%s' % (num, quality),
}
- elif stream_url.startswith('http'):
+ else:
f = {
'url': stream_url,
'format_id': 'a%s-%s-%s' % (num, ext, quality)
}
- else:
- continue
m = re.search(r'_(?P<width>\d+)x(?P<height>\d+)\.mp4$', stream_url)
if m:
f.update({