only parse 302 for known hosts eg spotify.link
This commit is contained in:
parent
e5c3347380
commit
27a45deb6e
1 changed files with 1 additions and 1 deletions
|
@ -298,7 +298,7 @@ class SiteManager:
|
|||
cls = next(
|
||||
filter(lambda p: p.validate_url(url), SiteManager.registry.values()), None
|
||||
)
|
||||
if cls is None:
|
||||
if cls is None and re.match(r"^https?://(spotify.link|t.co).+", url):
|
||||
try:
|
||||
url2 = requests.head(url, allow_redirects=True, timeout=1).url
|
||||
if url2 != url:
|
||||
|
|
Loading…
Add table
Reference in a new issue