From 1da5d1e0e2a77445d5a7a449a9d7b8738b7488ca Mon Sep 17 00:00:00 2001 From: agentik-007 Date: Mon, 16 May 2016 14:31:36 +0300 Subject: [PATCH] Update webhook_flask_echo_bot.py --- examples/webhook_examples/webhook_flask_echo_bot.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/webhook_examples/webhook_flask_echo_bot.py b/examples/webhook_examples/webhook_flask_echo_bot.py index 418e3ab..26b189e 100644 --- a/examples/webhook_examples/webhook_flask_echo_bot.py +++ b/examples/webhook_examples/webhook_flask_echo_bot.py @@ -48,7 +48,7 @@ def index(): @app.route(WEBHOOK_URL_PATH, methods=['POST']) def webhook(): if flask.request.headers.get('content-type') == 'application/json': - json_string = flask.request.get_data().decode('utf-8') + json_string = flask.request.get_data().encode('utf-8') update = telebot.types.Update.de_json(json_string) bot.process_new_messages([update.message]) return ''