aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMelody Horn <melody@boringcactus.com>2020-06-18 23:48:33 -0600
committerMelody Horn <melody@boringcactus.com>2020-06-18 23:48:33 -0600
commit1d7b7edcf64b9a7ba3f2e5a00d55f607ef77e83d (patch)
tree337c242fa07aa00df7011b4348669fde309f84d9
parent0b634e21698e0b6dcc00cb39e88b9604536fc0ca (diff)
downloadcrabravebot-1d7b7edcf64b9a7ba3f2e5a00d55f607ef77e83d.tar.gz
crabravebot-1d7b7edcf64b9a7ba3f2e5a00d55f607ef77e83d.zip
a few tiny things
-rw-r--r--bot.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/bot.py b/bot.py
index 5b77632..d9392ff 100644
--- a/bot.py
+++ b/bot.py
@@ -179,6 +179,7 @@ WEBHOOK = '/webhook/' + TOKEN
@app.route(WEBHOOK, methods=['POST'])
def webhook():
update_queue.put(telegram.Update.de_json(request.get_json(), bot))
+ return 'ok'
bot = telegram.Bot(token=TOKEN)
@@ -188,7 +189,7 @@ dp = Dispatcher(bot, update_queue, use_context=True)
# Add handlers
dp.add_handler(CommandHandler('start', start))
dp.add_handler(InlineQueryHandler(inline_query))
-dp.add_handler(MessageHandler(Filters.all, message))
+dp.add_handler(MessageHandler(Filters.text, message))
thread = Thread(target=dp.start, name='dispatcher')
thread.start()