Merge pull request #322 from khapaev/update-get_domain_hyperlinks-function

Added or link.startswith("tel:") in the condition to exclude tel: links from clean links.
pull/325/head
Ted Sanders 1 year ago committed by GitHub
commit 21ea80afc8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -87,7 +87,11 @@ def get_domain_hyperlinks(local_domain, url):
else:
if link.startswith("/"):
link = link[1:]
elif link.startswith("#") or link.startswith("mailto:"):
elif (
link.startswith("#")
or link.startswith("mailto:")
or link.startswith("tel:")
):
continue
clean_link = "https://" + local_domain + "/" + link

Loading…
Cancel
Save