From 2882147492453b439f33ae4dfda0b02df6176115 Mon Sep 17 00:00:00 2001 From: "Francesco Scarlato (Jungmann)" Date: Thu, 25 May 2017 19:52:28 +0200 Subject: [PATCH] Fix sintax error --- django_telegrambot/apps.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/django_telegrambot/apps.py b/django_telegrambot/apps.py index 869925d..2c06507 100644 --- a/django_telegrambot/apps.py +++ b/django_telegrambot/apps.py @@ -167,7 +167,7 @@ def ready(self): if self.mode == WEBHOOK_MODE: try: bot = telegram.Bot(token=token) - except InvalidToken + except InvalidToken: logger.error('Invalid Token : {}'.format(token)) return DjangoTelegramBot.dispatchers.append(Dispatcher(bot, None, workers=0)) @@ -189,7 +189,7 @@ def ready(self): DjangoTelegramBot.updaters.append(updater) DjangoTelegramBot.dispatchers.append(updater.dispatcher) DjangoTelegramBot.__used_tokens.add(token) - except InvalidToken + except InvalidToken: logger.error('Invalid Token : {}'.format(token)) return