fix twitter robot

This commit is contained in:
bakatrouble 2021-04-24 00:30:14 +03:00
parent c8e0af9bd9
commit a844ab23d9

View File

@ -91,7 +91,7 @@ class RobotBotModuleConfig(TelegramBotModuleConfig):
tweet = api.GetStatus(twitter_matches.group(1)) tweet = api.GetStatus(twitter_matches.group(1))
try: try:
for media in tweet.media: for media in tweet.media:
if media['type'] == 'video': if media.type == 'video':
max_bitrate = -1 max_bitrate = -1
max_bitrate_link = None max_bitrate_link = None
for variant in media.video_unfo['variants']: for variant in media.video_unfo['variants']: