]> gitweb @ CieloNegro.org - youtube-dl.git/commitdiff
[thescene] Fix extraction (closes #12235)
authorThomas Christlieb <thomaschristlieb@hotmail.com>
Fri, 24 Feb 2017 14:08:45 +0000 (15:08 +0100)
committerSergey M <dstftw@gmail.com>
Fri, 24 Feb 2017 14:08:45 +0000 (22:08 +0800)
youtube_dl/extractor/thescene.py

index ce1326c03643186b4e1eb58905ef8f9c868588f6..6c16d66ed68557ebbdf0a80065fdef946252493d 100644 (file)
@@ -32,7 +32,7 @@ class TheSceneIE(InfoExtractor):
         player = self._download_webpage(player_url, display_id)
         info = self._parse_json(
             self._search_regex(
-                r'(?m)var\s+video\s+=\s+({.+?});$', player, 'info json'),
+                r'(?m)video\s*:\s*({.+?}),$', player, 'info json'),
             display_id)
 
         qualities_order = qualities(('low', 'high'))
@@ -40,7 +40,7 @@ class TheSceneIE(InfoExtractor):
             'format_id': '{0}-{1}'.format(f['type'].split('/')[0], f['quality']),
             'url': f['src'],
             'quality': qualities_order(f['quality']),
-        } for f in info['sources'][0]]
+        } for f in info['sources']]
         self._sort_formats(formats)
 
         return {