[Sync] Token is_url changed: match whole string as a url
This commit is contained in:
1 parent
ec73ad0ef2
commit
c3514ae818
1 file changed
+1
-5
@@ -184,11 +184,7 @@ def markdown_to_html(text):
|
|||||||
|
|
||||||
|
|
||||||
def is_url(sample: str):
|
def is_url(sample: str):
|
||||||
link = parse_link(sample)
|
url = urlparse(sample)
|
||||||
if not link:
|
|
||||||
return False
|
|
||||||
|
|
||||||
url = link['url']
|
|
||||||
return url.scheme and url.netloc
|
return url.scheme and url.netloc
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user