mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2025-08-08 04:52:30 +00:00
Reuse code for _get_entity_pair
Less error-prone, improved the function flow for all callers, and removed some duplicate work.
This commit is contained in:
@@ -105,7 +105,8 @@ class CallbackQuery(EventBuilder):
|
||||
|
||||
def _set_client(self, client):
|
||||
super()._set_client(client)
|
||||
self._sender, self._input_sender = self._get_entity_pair(self.sender_id)
|
||||
self._sender, self._input_sender = utils._get_entity_pair(
|
||||
self.sender_id, self._entities, client._entity_cache)
|
||||
|
||||
@property
|
||||
def id(self):
|
||||
|
Reference in New Issue
Block a user