diff options
author | Naglis Jonaitis <njonaitis@gmail.com> | 2015-03-20 01:50:36 +0200 |
---|---|---|
committer | Naglis Jonaitis <njonaitis@gmail.com> | 2015-03-20 01:50:36 +0200 |
commit | 2684871bc10fe2b34f58312b6f75d3237a786732 (patch) | |
tree | c155940e6f647b217a43e8ae7bc9a43afa2bf7ee /youtube_dl | |
parent | ccf3960eeca3ca8b75da709c8c3019531101f1e7 (diff) |
[vine] Fix formats extraction (Closes #5239)
Diffstat (limited to 'youtube_dl')
-rw-r--r-- | youtube_dl/extractor/vine.py | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/youtube_dl/extractor/vine.py b/youtube_dl/extractor/vine.py index 0b58fe0fe..c3187cfeb 100644 --- a/youtube_dl/extractor/vine.py +++ b/youtube_dl/extractor/vine.py @@ -33,14 +33,13 @@ class VineIE(InfoExtractor): r'window\.POST_DATA = { %s: ({.+?}) }' % video_id, webpage, 'vine data')) formats = [{ - 'url': data['videoLowURL'], - 'ext': 'mp4', - 'format_id': 'low', - }, { - 'url': data['videoUrl'], - 'ext': 'mp4', - 'format_id': 'standard', - }] + 'format_id': '%(format)s-%(rate)s' % f, + 'vcodec': f['format'], + 'quality': f['rate'], + 'url': f['videoUrl'], + } for f in data['videoUrls'] if f.get('rate')] + + self._sort_formats(formats) return { 'id': video_id, |