fix: made coco reset return on error

This commit is contained in:
Seaswimmer 2023-08-08 10:54:11 -04:00
parent 183f8b29b0
commit 578a28e3b5
No known key found for this signature in database
GPG key ID: 5019678FD9CF50D8

View file

@ -133,6 +133,7 @@ class Galaxy(commands.Cog):
emoji_obj = self.bot.get_emoji(emoji_id)
if emoji_obj is None:
await interaction.response.send_message(content="You're trying to set the coco emoji to an emoji I don't have access to!", ephemeral=True)
return
await self.config.guild(interaction.guild).cocoemoji.set(emoji_obj.id)
embed=discord.Embed(color=await self.bot.get_embed_color(None), description=f"Coco's emoji has been set to {emoji_obj} ({emoji_obj.id}).")
await interaction.response.send_message(embed=embed)