From b4969f3d4a94d0bfc73c13a5fd510b16f34702a9 Mon Sep 17 00:00:00 2001 From: Kreusada <67752638+Kreusada@users.noreply.github.com> Date: Sun, 3 Sep 2023 20:55:13 +0100 Subject: [PATCH] [EmbedCreator] v1.0.1 Allow role mentions inside message content --- docs/cog_embedcreator.rst | 2 +- embedcreator/README.rst | 2 +- embedcreator/embedcreator.py | 8 ++++++-- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/docs/cog_embedcreator.rst b/docs/cog_embedcreator.rst index 1c574d598..29529a869 100644 --- a/docs/cog_embedcreator.rst +++ b/docs/cog_embedcreator.rst @@ -12,7 +12,7 @@ Through this guide, ``[p]`` will always represent your prefix. Replace .. note:: - This guide was last updated for version 1.0.0. Ensure + This guide was last updated for version 1.0.1. Ensure that you are up to date by running ``[p]cog update embedcreator``. If there is something missing, or something that needs improving diff --git a/embedcreator/README.rst b/embedcreator/README.rst index 1c574d598..29529a869 100644 --- a/embedcreator/README.rst +++ b/embedcreator/README.rst @@ -12,7 +12,7 @@ Through this guide, ``[p]`` will always represent your prefix. Replace .. note:: - This guide was last updated for version 1.0.0. Ensure + This guide was last updated for version 1.0.1. Ensure that you are up to date by running ``[p]cog update embedcreator``. If there is something missing, or something that needs improving diff --git a/embedcreator/embedcreator.py b/embedcreator/embedcreator.py index 5865cde4c..06866ecbc 100644 --- a/embedcreator/embedcreator.py +++ b/embedcreator/embedcreator.py @@ -574,7 +574,11 @@ async def send(self, interaction: discord.Interaction, select: discord.ui.Channe f"I do not have permissions to post in {channel.mention}.", ephemeral=True ) try: - await channel.send(embed=self.embed, content=self.content) + await channel.send( + embed=self.embed, + content=self.content, + allowed_mentions=discord.AllowedMentions(roles=True), + ) except discord.HTTPException: return await interaction.response.send_message( "Something went wrong whilst sending the embed." @@ -623,7 +627,7 @@ class EmbedCreator(commands.Cog): """Create embeds using buttons, modals and dropdowns!""" __author__ = "Kreusada" - __version__ = "1.0.0" + __version__ = "1.0.1" def __init__(self, bot: Red): self.bot = bot