@@ -61,22 +61,29 @@ def async_func(*args, **kwargs):
6161class Dispatcher :
6262 """
6363 This class dispatches all kinds of updates to its registered handlers.
64+ A handler is a function that usually takes the following parameters
6465
65- A handler is a function that usually takes the following parameters:
66- bot: The telegram.Bot instance that received the message
67- update: The update that should be handled by the handler
66+ bot:
67+ The telegram.Bot instance that received the message
68+ update:
69+ The update that should be handled by the handler
6870
69- Error handlers take an additional parameter:
70- error: The TelegramError instance that was raised during processing the
71+ Error handlers take an additional parameter
72+
73+ error:
74+ The TelegramError instance that was raised during processing the
7175 update
7276
7377 All handlers, except error handlers, can also request more information by
7478 appending one or more of the following arguments in their argument list for
75- convenience:
76- update_queue: The Queue instance which contains all new updates and is
79+ convenience
80+
81+ update_queue:
82+ The Queue instance which contains all new updates and is
7783 processed by the Dispatcher. Be careful with this - you might
7884 create an infinite loop.
79- args: If the update is an instance str or telegram.Update, this will be
85+ args:
86+ If the update is an instance str or telegram.Update, this will be
8087 a list that contains the content of the message split on spaces,
8188 except the first word (usually the command).
8289 Example: '/add item1 item2 item3' -> ['item1', 'item2', 'item3']
0 commit comments