mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-21 10:17:59 -05:00
[Customcom] Fix error on exiting customcom interactive menu. (#3417)
* [Customcom] Fixes error on exit * Changelog * Fixed spelling. * Typehinting
This commit is contained in:
@@ -227,6 +227,9 @@ class CustomCommands(commands.Cog):
|
||||
await ctx.send(_("There already exists a bot command with the same name."))
|
||||
return
|
||||
responses = await self.commandobj.get_responses(ctx=ctx)
|
||||
if not responses:
|
||||
await ctx.send(_("Custom command process cancelled."))
|
||||
return
|
||||
try:
|
||||
await self.commandobj.create(ctx=ctx, command=command, response=responses)
|
||||
await ctx.send(_("Custom command successfully added."))
|
||||
|
||||
Reference in New Issue
Block a user