diff --git a/pyrogram/client/handlers/disconnect_handler.py b/pyrogram/client/handlers/disconnect_handler.py index 67d0ae02..71123248 100644 --- a/pyrogram/client/handlers/disconnect_handler.py +++ b/pyrogram/client/handlers/disconnect_handler.py @@ -20,6 +20,19 @@ from .handler import Handler class DisconnectHandler(Handler): - # TODO: Documentation + """The Disconnect handler class. Used to handle disconnections. It is intended to be used with + :meth:`add_handler() ` + + + Args: + callback (``callable``): + Pass a function that will be called when a disconnection occurs. It takes *(client)* + as positional argument (look at the section below for a detailed description). + + Other parameters: + client (:obj:`Client `): + The Client itself. Useful, for example, when you want to change the proxy before a new connection + is established. + """ def __init__(self, callback: callable): super().__init__(callback)