1
0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2025-06-27 17:08:32 +00:00

Update yt_dlp/extractor/dzsecurity.py

Co-authored-by: D Trombett <d@trombett.org>
This commit is contained in:
CasperMcFadden95 2025-06-18 18:57:52 +00:00 committed by GitHub
parent bd8498acda
commit ea4ac61edd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -47,15 +47,12 @@ def _real_extract(self, url):
title = self._html_extract_title(webpage, default='Live Stream')
player_url_match = re.search(
player_url, stream_id = self._html_search_regex(
r'https://live\.dzsecurity\.net/live/player/([a-zA-Z0-9_-]+)',
webpage,
'player URL',
group=(0, 1)
)
if not player_url_match:
raise ExtractorError('Player URL not found in the page')
player_url = player_url_match.group(0)
stream_id = player_url_match.group(1)
base_url_match = re.match(r'(https?://[^/]+)', url)
if not base_url_match: