From 572a3f03410b3a8949955f7c8fc10a69ba27f820 Mon Sep 17 00:00:00 2001 From: Jeremy Zhang Date: Thu, 1 Mar 2018 08:37:39 +0000 Subject: [PATCH] Not all emojis have the animated attr yet hotfix --- webapp/titanembeds/blueprints/api/api.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/webapp/titanembeds/blueprints/api/api.py b/webapp/titanembeds/blueprints/api/api.py index 6ac5610..cfac41c 100644 --- a/webapp/titanembeds/blueprints/api/api.py +++ b/webapp/titanembeds/blueprints/api/api.py @@ -21,7 +21,7 @@ def parse_emoji(textToParse, guild_id): for gemoji in guild_emojis: emoji_name = gemoji["name"] emoji_id = gemoji["id"] - emoji_animated = gemoji["animated"] + emoji_animated = gemoji.get("animated", False) if emoji_animated: textToParse = textToParse.replace(":{}:".format(emoji_name), "".format(emoji_name, emoji_id)) else: