AAA3A-AAA3A/AAA3A-cogs

[LinkQuoter] Add an option to toggle the `delete_message` button.

Closed this issue · 4 comments

What cog is this feature request for?

linkquoter

Describe the feature request in as much detail as possible

Proposal

I would like to be able to toggle the delete_message button appearing on link quoted messages, so that they don't appear in the first place.

Maybe an extra option like showdeletemessagebutton or equivalent? This could be set to True as the default, mimicking the current behaviour.

Relevant code block that would need to be "toggle-able":

@discord.ui.button(emoji="✖️", style=discord.ButtonStyle.danger, custom_id="delete_message")
async def delete_message(self, interaction: discord.Interaction, button: discord.ui.Button) -> None:
await CogsUtils.delete_message(self._message)
self.stop()

Thank you so much! <3 @AAA3A-AAA3A

Hi again @AAA3A-AAA3A... I've just ran the following commands

cog update linkquoter
reload linkquoter
setlinkquoter deletemessagebutton False

and unfortunately receiving the following error message when quoting a message:

Error in [hybrid|text] command 'linkquote'. Check your console or logs for details. If necessary, please inform the creator of the cog in which this command is located. Thank you.
You can send this error to the developer by running the following command:
~AAA3A_utils senderrorwithsentry b82ac24feb29464290b0e0f7d645cd45

Would you happen to know what's going wrong here?

(Apologies, I thought I could reopen the issue and commented here, let me know if you want me to create a bug report issue for this)

No need to recreate a bug report. lol Should be fixed with 3a8ee9b6.

works perfectly, thank you!