From 6e4b6bdca86a1554675633c501478159a579c4fb Mon Sep 17 00:00:00 2001 From: Nick80835 <24271245+Nick80835@users.noreply.github.com> Date: Wed, 5 Mar 2025 07:52:12 -0500 Subject: [PATCH] Make URL regex match anything again Including spaces. --- telethon/extensions/markdown.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/telethon/extensions/markdown.py b/telethon/extensions/markdown.py index 032f7eef..b69195ee 100644 --- a/telethon/extensions/markdown.py +++ b/telethon/extensions/markdown.py @@ -22,7 +22,7 @@ DEFAULT_DELIMITERS = { '```': MessageEntityPre } -DEFAULT_URL_RE = re.compile(r'\[([\s\S]+?)\]\((.+?)\)') +DEFAULT_URL_RE = re.compile(r'\[([\s\S]*?)\]\(([\s\S]*?)\)') DEFAULT_URL_FORMAT = '[{0}]({1})'