mirror of
https://gitlab.com/simple-stock-bots/simple-stock-bot.git
synced 2025-06-16 07:16:40 +00:00
bot now types in chat while its working.
This commit is contained in:
parent
74e63bb697
commit
9f87a86bde
6
bot.py
6
bot.py
@ -39,6 +39,9 @@ def tickerDetect(bot, update):
|
||||
message = update.message.text
|
||||
chat_id = update.message.chat_id
|
||||
|
||||
# Let user know bot is working
|
||||
bot.send_chat_action(chat_id=chat_id, action=telegram.ChatAction.TYPING)
|
||||
|
||||
tickers = getTickers(message)
|
||||
|
||||
data = tickerData(tickers) if tickers else {}
|
||||
@ -68,6 +71,9 @@ def news(bot, update):
|
||||
message = update.message.text
|
||||
chat_id = update.message.chat_id
|
||||
|
||||
# Let user know bot is working
|
||||
bot.send_chat_action(chat_id=chat_id, action=telegram.ChatAction.TYPING)
|
||||
|
||||
tickers = getTickers(message)
|
||||
|
||||
news = tickerNews(tickers) if tickers else {}
|
||||
|
Loading…
x
Reference in New Issue
Block a user