mirror of
https://github.com/python-telegram-bot/python-telegram-bot.git
synced 2024-11-22 15:17:00 +01:00
Fixes regression on Audio and Document models for unicode fields #65
This commit is contained in:
parent
797a3e6ea4
commit
855ab19dea
2 changed files with 3 additions and 3 deletions
|
@ -52,8 +52,8 @@ class Audio(TelegramObject):
|
|||
self.file_id = str(file_id)
|
||||
self.duration = int(duration)
|
||||
# Optionals
|
||||
self.performer = str(kwargs.get('performer', ''))
|
||||
self.title = str(kwargs.get('title', ''))
|
||||
self.performer = kwargs.get('performer', '')
|
||||
self.title = kwargs.get('title', '')
|
||||
self.mime_type = str(kwargs.get('mime_type', ''))
|
||||
self.file_size = int(kwargs.get('file_size', 0))
|
||||
|
||||
|
|
|
@ -49,7 +49,7 @@ class Document(TelegramObject):
|
|||
self.file_id = str(file_id)
|
||||
# Optionals
|
||||
self.thumb = kwargs.get('thumb')
|
||||
self.file_name = str(kwargs.get('file_name', ''))
|
||||
self.file_name = kwargs.get('file_name', '')
|
||||
self.mime_type = str(kwargs.get('mime_type', ''))
|
||||
self.file_size = int(kwargs.get('file_size', 0))
|
||||
|
||||
|
|
Loading…
Reference in a new issue