diff options
author | Sergey M․ <dstftw@gmail.com> | 2017-08-12 19:24:26 +0700 |
---|---|---|
committer | Sergey M․ <dstftw@gmail.com> | 2017-08-12 19:24:26 +0700 |
commit | 868f79db41a4d81a87ef12c8bd5ef73205c9c029 (patch) | |
tree | ba71740898641a9544406752f9b900b79154f88e | |
parent | 70851a95c307880f016fcb6f37427a8eeae73cad (diff) |
[extractor/common] Fix _media_formats
-rw-r--r-- | youtube_dl/extractor/common.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/youtube_dl/extractor/common.py b/youtube_dl/extractor/common.py index e565901af..7fe888462 100644 --- a/youtube_dl/extractor/common.py +++ b/youtube_dl/extractor/common.py @@ -2115,7 +2115,7 @@ class InfoExtractor(object): return f return {} - def _media_formats(src, type_info, cur_media_type): + def _media_formats(src, cur_media_type, type_info={}): full_url = absolute_url(src) ext = type_info.get('ext') or determine_ext(full_url) if ext == 'm3u8': @@ -2167,7 +2167,7 @@ class InfoExtractor(object): if not src: continue f = parse_content_type(source_attributes.get('type')) - is_plain_url, formats = _media_formats(src, f, media_type) + is_plain_url, formats = _media_formats(src, media_type, f) if is_plain_url: f.update(formats[0]) media_info['formats'].append(f) |