mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2024-11-25 19:03:46 +03:00
Parse t.me/@<user> URLs as valid usernames
This commit is contained in:
parent
c1774276c2
commit
75ca28df49
|
@ -50,7 +50,7 @@ mimetypes.add_type('audio/ogg', '.ogg')
|
||||||
mimetypes.add_type('audio/flac', '.flac')
|
mimetypes.add_type('audio/flac', '.flac')
|
||||||
|
|
||||||
USERNAME_RE = re.compile(
|
USERNAME_RE = re.compile(
|
||||||
r'@|(?:https?://)?(?:www\.)?(?:telegram\.(?:me|dog)|t\.me)/(joinchat/)?'
|
r'@|(?:https?://)?(?:www\.)?(?:telegram\.(?:me|dog)|t\.me)/(@|joinchat/)?'
|
||||||
)
|
)
|
||||||
TG_JOIN_RE = re.compile(
|
TG_JOIN_RE = re.compile(
|
||||||
r'tg://(join)\?invite='
|
r'tg://(join)\?invite='
|
||||||
|
|
Loading…
Reference in New Issue
Block a user