2
0
mirror of https://github.com/pyrogram/pyrogram synced 2025-09-05 00:35:10 +00:00

Merge branch 'develop' into asyncio

# Conflicts:
#	pyrogram/__init__.py
This commit is contained in:
Dan
2019-06-07 16:36:49 +02:00
15 changed files with 47 additions and 42 deletions

View File

@@ -24,7 +24,7 @@ if sys.version_info[:3] in [(3, 5, 0), (3, 5, 1), (3, 5, 2)]:
# Monkey patch the standard "typing" module because Python versions from 3.5.0 to 3.5.2 have a broken one.
sys.modules["typing"] = typing
__version__ = "0.13.0-asyncio"
__version__ = "0.14.0-asyncio"
__license__ = "GNU Lesser General Public License v3 or later (LGPLv3+)"
__copyright__ = "Copyright (C) 2017-2019 Dan <https://github.com/delivrance>"

View File

@@ -32,10 +32,11 @@ class OnCallbackQuery(BaseClient):
) -> callable:
"""Decorator for handling callback queries.
This does the same thing as :meth:`~Client.add_handler` using the :obj:`CallbackQueryHandler`.
This does the same thing as :meth:`~pyrogram.Client.add_handler` using the
:obj:`~pyrogram.CallbackQueryHandler`.
Parameters:
filters (:obj:`Filters`):
filters (:obj:`~pyrogram.Filters`, *optional*):
Pass one or more filters to allow only a subset of callback queries to be passed
in your function.

View File

@@ -32,10 +32,11 @@ class OnDeletedMessages(BaseClient):
) -> callable:
"""Decorator for handling deleted messages.
This does the same thing as :meth:`~Client.add_handler` using the :obj:`DeletedMessagesHandler`.
This does the same thing as :meth:`~pyrogram.Client.add_handler` using the
:obj:`~pyrogram.DeletedMessagesHandler`.
Parameters:
filters (:obj:`Filters`):
filters (:obj:`~pyrogram.Filters`, *optional*):
Pass one or more filters to allow only a subset of messages to be passed
in your function.

View File

@@ -25,7 +25,7 @@ class OnDisconnect(BaseClient):
def on_disconnect(self=None) -> callable:
"""Decorator for handling disconnections.
This does the same thing as :meth:`~Client.add_handler` using the :obj:`DisconnectHandler`.
This does the same thing as :meth:`~pyrogram.Client.add_handler` using the :obj:`~pyrogram.DisconnectHandler`.
"""
def decorator(func: callable) -> Handler:

View File

@@ -32,10 +32,10 @@ class OnInlineQuery(BaseClient):
) -> callable:
"""Decorator for handling inline queries.
This does the same thing as :meth:`~Client.add_handler` using the :obj:`InlineQueryHandler`.
This does the same thing as :meth:`~pyrogram.Client.add_handler` using the :obj:`~pyrogram.InlineQueryHandler`.
Parameters:
filters (:obj:`Filters <pyrogram.Filters>`):
filters (:obj:`~pyrogram.Filters`, *optional*):
Pass one or more filters to allow only a subset of inline queries to be passed
in your function.

View File

@@ -32,10 +32,10 @@ class OnMessage(BaseClient):
) -> callable:
"""Decorator for handling messages.
This does the same thing as :meth:`~Client.add_handler` using the :obj:`MessageHandler`.
This does the same thing as :meth:`~pyrogram.Client.add_handler` using the :obj:`~pyrogram.MessageHandler`.
Parameters:
filters (:obj:`Filters`):
filters (:obj:`~pyrogram.Filters`, *optional*):
Pass one or more filters to allow only a subset of messages to be passed
in your function.

View File

@@ -32,10 +32,10 @@ class OnPoll(BaseClient):
) -> callable:
"""Decorator for handling poll updates.
This does the same thing as :meth:`~Client.add_handler` using the :obj:`PollHandler`.
This does the same thing as :meth:`~pyrogram.Client.add_handler` using the :obj:`~pyrogram.PollHandler`.
Parameters:
filters (:obj:`Filters`):
filters (:obj:`~pyrogram.Filters`, *optional*):
Pass one or more filters to allow only a subset of polls to be passed
in your function.

View File

@@ -30,7 +30,7 @@ class OnRawUpdate(BaseClient):
) -> callable:
"""Decorator for handling raw updates.
This does the same thing as :meth:`~Client.add_handler` using the :obj:`RawUpdateHandler`.
This does the same thing as :meth:`~pyrogram.Client.add_handler` using the :obj:`~pyrogram.RawUpdateHandler`.
Parameters:
group (``int``, *optional*):

View File

@@ -31,10 +31,10 @@ class OnUserStatus(BaseClient):
group: int = 0
) -> callable:
"""Decorator for handling user status updates.
This does the same thing as :meth:`~Client.add_handler` using the :obj:`UserStatusHandler`.
This does the same thing as :meth:`~pyrogram.Client.add_handler` using the :obj:`~pyrogram.UserStatusHandler`.
Parameters:
filters (:obj:`Filters`):
filters (:obj:`~pyrogram.Filters`, *optional*):
Pass one or more filters to allow only a subset of UserStatus updated to be passed in your function.
group (``int``, *optional*):