From 2e212546d3390d1578dab4aa6405d8b89b227a28 Mon Sep 17 00:00:00 2001 From: Oleg A Date: Fri, 13 Nov 2020 17:57:29 +0300 Subject: [PATCH] #463 removed document and audio from check --- aiogram/types/input_media.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/aiogram/types/input_media.py b/aiogram/types/input_media.py index 5c16e21a..2c782af5 100644 --- a/aiogram/types/input_media.py +++ b/aiogram/types/input_media.py @@ -282,7 +282,7 @@ class MediaGroup(base.TelegramObject): elif not isinstance(media, InputMedia): raise TypeError(f"Media must be an instance of InputMedia or dict, not {type(media).__name__}") - elif media.type in ('document', 'audio', 'animation'): + elif media.type in ('animation', ): raise ValueError(f"This type of media is not supported by media groups!") self.media.append(media)