[bellazon] improve video URL regex (#8392)

match <source> elements with attributes before 'src="..."'
This commit is contained in:
Mike Fährmann
2025-10-12 08:35:32 +02:00
parent 65feed5b64
commit f89f55b215
2 changed files with 11 additions and 1 deletions

View File

@@ -27,7 +27,7 @@ class BellazonExtractor(Extractor):
native = (f"{self.root}/", f"{self.root[6:]}/")
extract_urls = text.re(
r'(?s)<('
r'(?:video .*?<source src|a [^>]*?href)="([^"]+).*?</a>'
r'(?:video .*?<source [^>]*?src|a [^>]*?href)="([^"]+).*?</a>'
r'|img [^>]*?src="([^"]+)"[^>]*>'
r')'
).findall