mirror of
https://github.com/RYGhub/royalnet.git
synced 2024-11-23 19:44:20 +00:00
Send typing notifications on telegram commands
This commit is contained in:
parent
e078b639d3
commit
22b8cdf97f
1 changed files with 2 additions and 0 deletions
|
@ -113,6 +113,8 @@ class TelegramBot(GenericBot):
|
|||
# Find and clean parameters
|
||||
command_text, *parameters = text.split(" ")
|
||||
command_name = command_text.replace(f"@{self.client.username}", "").lower()
|
||||
# Send a typing notification
|
||||
self.client.send_chat_action(update.message.chat, telegram.ChatAction.TYPING)
|
||||
# Call the command
|
||||
await self.call(command_name, update.message.chat, parameters, update=update)
|
||||
|
||||
|
|
Loading…
Reference in a new issue