Used edit_message_text
to reply
if message_id
is in kwargs
This commit is contained in:
parent
3cb912154b
commit
948ebcd015
@ -7,7 +7,7 @@ __author__ = "Davide Testa"
|
|||||||
__email__ = "davide@davte.it"
|
__email__ = "davide@davte.it"
|
||||||
__credits__ = ["Marco Origlia", "Nick Lee @Nickoala"]
|
__credits__ = ["Marco Origlia", "Nick Lee @Nickoala"]
|
||||||
__license__ = "GNU General Public License v3.0"
|
__license__ = "GNU General Public License v3.0"
|
||||||
__version__ = "2.1.9"
|
__version__ = "2.1.10"
|
||||||
__maintainer__ = "Davide Testa"
|
__maintainer__ = "Davide Testa"
|
||||||
__contact__ = "t.me/davte"
|
__contact__ = "t.me/davte"
|
||||||
|
|
||||||
|
@ -922,7 +922,10 @@ class Bot(TelegramBot, ObjectWithDatabase):
|
|||||||
"""Reply to `update` with proper method according to `kwargs`."""
|
"""Reply to `update` with proper method according to `kwargs`."""
|
||||||
method = None
|
method = None
|
||||||
if 'text' in kwargs:
|
if 'text' in kwargs:
|
||||||
method = self.send_message
|
if 'message_id' in kwargs:
|
||||||
|
method = self.edit_message_text
|
||||||
|
else:
|
||||||
|
method = self.send_message
|
||||||
elif 'photo' in kwargs:
|
elif 'photo' in kwargs:
|
||||||
method = self.send_photo
|
method = self.send_photo
|
||||||
if method is not None:
|
if method is not None:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user