Set supports_streaming to None if not mp4

This commit is contained in:
blank X 2021-10-15 09:50:28 +07:00
parent e869ec8373
commit d4f2f25ac4
Signed by: blankie
GPG Key ID: CC15FC822C7F61F5
1 changed files with 1 additions and 1 deletions

View File

@ -222,7 +222,7 @@ async def main():
except Exception:
logging.exception('Exception when getting video data')
else:
attributes.append(DocumentAttributeVideo(duration, w, h, supports_streaming=mimetype == 'video/mp4'))
attributes.append(DocumentAttributeVideo(duration, w, h, supports_streaming=mimetype == 'video/mp4' or None))
await client.send_message(chat, j, file=k, link_preview=False, attributes=attributes)
async def _get_video_data(filename):