Explorar el Código

[deezer] Fix extraction (Closes #9086)

Sergey M․ hace 9 años
padre
commit
65150b41bb
Se han modificado 1 ficheros con 3 adiciones y 1 borrados
  1. 3 1
      youtube_dl/extractor/deezer.py

+ 3 - 1
youtube_dl/extractor/deezer.py

@@ -41,7 +41,9 @@ class DeezerPlaylistIE(InfoExtractor):
                 'Deezer said: %s' % geoblocking_msg, expected=True)
 
         data_json = self._search_regex(
-            r'naboo\.display\(\'[^\']+\',\s*(.*?)\);\n', webpage, 'data JSON')
+            (r'__DZR_APP_STATE__\s*=\s*({.+?})\s*</script>',
+             r'naboo\.display\(\'[^\']+\',\s*(.*?)\);\n'),
+            webpage, 'data JSON')
         data = json.loads(data_json)
 
         playlist_title = data.get('DATA', {}).get('TITLE')