mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2025-01-23 15:54:12 +03:00
Fix infinite recursion on .get_entity by exact name
This commit is contained in:
parent
0731a1d698
commit
7f35ed59c6
|
@ -1934,8 +1934,8 @@ class TelegramClient(TelegramBareClient):
|
|||
return entity
|
||||
try:
|
||||
# Nobody with this username, maybe it's an exact name/title
|
||||
return self.get_entity(self.get_input_entity(string))
|
||||
except (ValueError, TypeError):
|
||||
return self.get_entity(self.session.get_input_entity(string))
|
||||
except ValueError:
|
||||
pass
|
||||
|
||||
raise TypeError(
|
||||
|
|
Loading…
Reference in New Issue
Block a user