mirror of
https://github.com/LonamiWebs/Telethon
synced 2025-08-22 09:57:32 +00:00
Make markdown URL regex less greedy
Fixes multiple URLs in a single message.
This commit is contained in:
parent
551c24f3e4
commit
141b620437
@ -22,7 +22,7 @@ DEFAULT_DELIMITERS = {
|
||||
'```': MessageEntityPre
|
||||
}
|
||||
|
||||
DEFAULT_URL_RE = re.compile(r'\[([\s\S]+)\]\((.+)\)')
|
||||
DEFAULT_URL_RE = re.compile(r'\[([\s\S]+?)\]\((.+?)\)')
|
||||
DEFAULT_URL_FORMAT = '[{0}]({1})'
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user