Stop sending gifs as images

This is often not the case, most gifs are animated and when
sent as images inside albums they lose the animation.
This commit is contained in:
Lonami Exo 2018-03-15 10:13:57 +01:00
parent 45b7318f08
commit d7ef0f5e09

View File

@ -322,7 +322,7 @@ def is_image(file):
if not isinstance(file, str): if not isinstance(file, str):
return False return False
_, ext = os.path.splitext(file) _, ext = os.path.splitext(file)
return re.match(r'\.(png|jpe?g|gif)', ext, re.IGNORECASE) return re.match(r'\.(png|jpe?g)', ext, re.IGNORECASE)
def is_audio(file): def is_audio(file):