Skip to content

Commit

Permalink
Use the entity cache in sender getter
Browse files Browse the repository at this point in the history
  • Loading branch information
Lonami committed May 2, 2019
1 parent 1a00de6 commit cb56c54
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions telethon/tl/custom/sendergetter.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 53,8 @@ def input_sender(self):
"""
if self._input_sender is None and self._sender_id and self._client:
try:
self._input_sender = self._client.session\
.get_input_entity(self._sender_id)
self._input_sender = \
self._client._entity_cache[self._sender_id]
except ValueError:
pass
return self._input_sender
Expand Down

0 comments on commit cb56c54

Please sign in to comment.