diff options
author | Jaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com> | 2015-12-04 14:26:34 +0100 |
---|---|---|
committer | Jaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com> | 2015-12-04 14:26:34 +0100 |
commit | 2a63b0f1109f3f1c1f2d8fd48bfa49b080048c98 (patch) | |
tree | aab1da7b05dba6624c34c48d257aec5e45ede0aa | |
parent | 07b88cffcea87326dd7ab42baf40fbcbc106dd26 (diff) |
[mixcloud] Fix extraction of the audio url (fixes #7751)
-rw-r--r-- | youtube_dl/extractor/mixcloud.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/youtube_dl/extractor/mixcloud.py b/youtube_dl/extractor/mixcloud.py index d47aeceda..c2b7ed9ab 100644 --- a/youtube_dl/extractor/mixcloud.py +++ b/youtube_dl/extractor/mixcloud.py @@ -64,7 +64,8 @@ class MixcloudIE(InfoExtractor): preview_url = self._search_regex( r'\s(?:data-preview-url|m-preview)="([^"]+)"', webpage, 'preview url') - song_url = preview_url.replace('/previews/', '/c/originals/') + song_url = re.sub(r'audiocdn(\d+)', r'stream\1', preview_url) + song_url = song_url.replace('/previews/', '/c/originals/') if not self._check_url(song_url, track_id, 'mp3'): song_url = song_url.replace('.mp3', '.m4a').replace('originals/', 'm4a/64/') if not self._check_url(song_url, track_id, 'm4a'): |