You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: telegram/ext/callbackqueryhandler.py
+4-2Lines changed: 4 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -29,7 +29,8 @@
29
29
30
30
classCallbackQueryHandler(Handler):
31
31
"""
32
-
Handler class to handle Telegram callback queries. Optionally based on a regex. Read the documentation of the ``re`` module for more information.
32
+
Handler class to handle Telegram callback queries. Optionally based on a regex.
33
+
Read the documentation of the ``re`` module for more information.
33
34
34
35
Args:
35
36
callback (function): A function that takes ``bot, update`` as
@@ -43,7 +44,8 @@ class CallbackQueryHandler(Handler):
43
44
``job_queue`` will be passed to the callback function. It will be a ``JobQueue``
44
45
instance created by the ``Updater`` which can be used to schedule new jobs.
45
46
Default is ``False``.
46
-
pattern (optional[str or Pattern]): Optional regex pattern. If not ``None`` The ``re.match`` function is used to determine if an update should be handled by this handler.
47
+
pattern (optional[str or Pattern]): Optional regex pattern. If not ``None`` ``re.match``
48
+
is used to determine if an update should be handled by this handler.
47
49
pass_groups (optional[bool]): If the callback should be passed the
48
50
result of ``re.match(pattern, data).groups()`` as a keyword
Copy file name to clipboardExpand all lines: telegram/ext/inlinequeryhandler.py
+4-2Lines changed: 4 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -28,7 +28,8 @@
28
28
29
29
classInlineQueryHandler(Handler):
30
30
"""
31
-
Handler class to handle Telegram inline queries. Optionally based on a regex. Read the documentation of the ``re`` module for more information.
31
+
Handler class to handle Telegram inline queries. Optionally based on a regex. Read the
32
+
documentation of the ``re`` module for more information.
32
33
33
34
Args:
34
35
callback (function): A function that takes ``bot, update`` as
@@ -42,7 +43,8 @@ class InlineQueryHandler(Handler):
42
43
``job_queue`` will be passed to the callback function. It will be a ``JobQueue``
43
44
instance created by the ``Updater`` which can be used to schedule new jobs.
44
45
Default is ``False``.
45
-
pattern (optional[str or Pattern]): Optional regex pattern. If not ``None`` The ``re.match`` function is used to determine if an update should be handled by this handler.
46
+
pattern (optional[str or Pattern]): Optional regex pattern. If not ``None`` ``re.match``
47
+
is used to determine if an update should be handled by this handler.
46
48
pass_groups (optional[bool]): If the callback should be passed the
47
49
result of ``re.match(pattern, query).groups()`` as a keyword
0 commit comments