aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl/extractor/soundcloud.py
diff options
context:
space:
mode:
authorSergey M․ <dstftw@gmail.com>2016-09-24 02:01:01 +0700
committerSergey M․ <dstftw@gmail.com>2016-09-24 02:01:01 +0700
commit24628cf7db46ecce3fe56d387266c556cd9210ba (patch)
tree2a1f4da1b154e3c21e3a185203ce0ed22ca07bff /youtube_dl/extractor/soundcloud.py
parent71ad00c09fecd3ecc84784cf215537cad0a79595 (diff)
[soundcloud:playlist] Provide video id for playlist entries (Closes #10733)
Diffstat (limited to 'youtube_dl/extractor/soundcloud.py')
-rw-r--r--youtube_dl/extractor/soundcloud.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/youtube_dl/extractor/soundcloud.py b/youtube_dl/extractor/soundcloud.py
index 513c54829..496cc5d8e 100644
--- a/youtube_dl/extractor/soundcloud.py
+++ b/youtube_dl/extractor/soundcloud.py
@@ -477,7 +477,11 @@ class SoundcloudPlaylistIE(SoundcloudIE):
data = self._download_json(
base_url + data, playlist_id, 'Downloading playlist')
- entries = [self.url_result(track['permalink_url'], 'Soundcloud') for track in data['tracks']]
+ entries = [
+ self.url_result(
+ track['permalink_url'], SoundcloudIE.ie_key(),
+ video_id=compat_str(track['id']) if track.get('id') else None)
+ for track in data['tracks'] if track.get('permalink_url')]
return {
'_type': 'playlist',