[soundlcoud] Set the correct extension for the tracks (fixes #1766)
authorJaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com>
Thu, 14 Nov 2013 18:45:39 +0000 (19:45 +0100)
committerJaime Marquínez Ferrándiz <jaime.marquinez.ferrandiz@gmail.com>
Thu, 14 Nov 2013 18:45:39 +0000 (19:45 +0100)
Some tracks are not in mp3 format, they can be wav files.

youtube_dl/extractor/soundcloud.py

index 4717fbb77e0ec21a26147b25d9cc3be2f83d9f94..83e1f055f80efa05d8db33d296fd4554466a24ad 100644 (file)
@@ -87,7 +87,7 @@ class SoundcloudIE(InfoExtractor):
             'uploader': info['user']['username'],
             'upload_date': unified_strdate(info['created_at']),
             'title':    info['title'],
-            'ext':      u'mp3',
+            'ext':      info.get('original_format', u'mp3'),
             'description': info['description'],
             'thumbnail': thumbnail,
         }