Improve raise of empty chat_id

This commit is contained in:
leandrotoledo 2015-09-07 15:53:43 -03:00
parent 69d705a99f
commit a409fc511d

View file

@ -138,7 +138,7 @@ class Bot(TelegramObject):
""" """
url, data = func(self, *args, **kwargs) url, data = func(self, *args, **kwargs)
if not kwargs.get('chat_id'): if not data.get('chat_id'):
raise TelegramError('Invalid chat_id.') raise TelegramError('Invalid chat_id.')
if kwargs.get('reply_to_message_id'): if kwargs.get('reply_to_message_id'):