Browse Source

[soundcloud:set:user] Support mobile URLs (Closes #5323)

Sergey M․ 10 years ago
parent
commit
c808ef81bb
1 changed files with 2 additions and 2 deletions
  1. 2 2
      youtube_dl/extractor/soundcloud.py

+ 2 - 2
youtube_dl/extractor/soundcloud.py

@@ -242,7 +242,7 @@ class SoundcloudIE(InfoExtractor):
 
 
 
 
 class SoundcloudSetIE(SoundcloudIE):
 class SoundcloudSetIE(SoundcloudIE):
-    _VALID_URL = r'https?://(?:www\.)?soundcloud\.com/(?P<uploader>[\w\d-]+)/sets/(?P<slug_title>[\w\d-]+)(?:/(?P<token>[^?/]+))?'
+    _VALID_URL = r'https?://(?:(?:www|m)\.)?soundcloud\.com/(?P<uploader>[\w\d-]+)/sets/(?P<slug_title>[\w\d-]+)(?:/(?P<token>[^?/]+))?'
     IE_NAME = 'soundcloud:set'
     IE_NAME = 'soundcloud:set'
     _TESTS = [{
     _TESTS = [{
         'url': 'https://soundcloud.com/the-concept-band/sets/the-royal-concept-ep',
         'url': 'https://soundcloud.com/the-concept-band/sets/the-royal-concept-ep',
@@ -287,7 +287,7 @@ class SoundcloudSetIE(SoundcloudIE):
 
 
 
 
 class SoundcloudUserIE(SoundcloudIE):
 class SoundcloudUserIE(SoundcloudIE):
-    _VALID_URL = r'https?://(www\.)?soundcloud\.com/(?P<user>[^/]+)/?((?P<rsrc>tracks|likes)/?)?(\?.*)?$'
+    _VALID_URL = r'https?://(?:(?:www|m)\.)?soundcloud\.com/(?P<user>[^/]+)/?((?P<rsrc>tracks|likes)/?)?(\?.*)?$'
     IE_NAME = 'soundcloud:user'
     IE_NAME = 'soundcloud:user'
     _TESTS = [{
     _TESTS = [{
         'url': 'https://soundcloud.com/the-concept-band',
         'url': 'https://soundcloud.com/the-concept-band',