Use custom.Message in events

This commit is contained in:
Lonami Exo
2018-05-31 13:30:22 +02:00
parent b241d80958
commit 9e4854fcce
5 changed files with 22 additions and 12 deletions

View File

@@ -103,6 +103,12 @@ class EventCommon(abc.ABC):
)
self.is_channel = isinstance(chat_peer, types.PeerChannel)
def _set_client(self, client):
"""
Setter so subclasses can act accordingly when the client is set.
"""
self._client = client
def _get_entity(self, msg_id, entity_id, chat=None):
"""
Helper function to call :tl:`GetMessages` on the give msg_id and