]> jfr.im git - yt-dlp.git/blobdiff - yt_dlp/extractor/dplay.py
[cleanup] Minor fixes (See desc)
[yt-dlp.git] / yt_dlp / extractor / dplay.py
index 54f95a44af0e1ed4ef7c1a3cb16f9494322f5cb6..5c4f3c8923124dcd6d7d596e3cf3eb8b5a547f19 100644 (file)
@@ -8,6 +8,7 @@
     ExtractorError,
     float_or_none,
     int_or_none,
+    remove_start,
     strip_or_none,
     try_get,
     unified_timestamp,
@@ -311,7 +312,7 @@ class DPlayIE(DPlayBaseIE):
     def _real_extract(self, url):
         mobj = self._match_valid_url(url)
         display_id = mobj.group('id')
-        domain = mobj.group('domain').lstrip('www.')
+        domain = remove_start(mobj.group('domain'), 'www.')
         country = mobj.group('country') or mobj.group('subdomain_country') or mobj.group('plus_country')
         host = 'disco-api.' + domain if domain[0] == 'd' else 'eu2-prod.disco-api.com'
         return self._get_disco_api_info(