mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2024-11-10 19:46:36 +03:00
Remove unnecessary call to .get_input_entity()
This commit is contained in:
parent
a1c669333e
commit
b346561f89
|
@ -504,7 +504,7 @@ class TelegramClient(TelegramBareClient):
|
|||
if limit == 0:
|
||||
# No messages, but we still need to know the total message count
|
||||
result = self(GetHistoryRequest(
|
||||
peer=self.get_input_entity(entity), limit=1,
|
||||
peer=entity, limit=1,
|
||||
offset_date=None, offset_id=0, max_id=0, min_id=0, add_offset=0
|
||||
))
|
||||
return getattr(result, 'count', len(result.messages)), [], []
|
||||
|
|
Loading…
Reference in New Issue
Block a user