Skip to content

Commit

Permalink
small improvement
Browse files Browse the repository at this point in the history
  • Loading branch information
QuantumChemist committed Oct 3, 2024
1 parent 240bd87 commit 843a362
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions bot.py
Original file line number Diff line number Diff line change
Expand Up @@ -828,8 +828,9 @@ async def on_app_command_error(self, interaction: discord.Interaction, error: ap
if isinstance(error, app_commands.MissingPermissions):
if interaction.command.name == "logout":
await interaction.response.send_message(
"Error: You do not have permission to use this command. Only the bot owner can use the `logout` command.",
ephemeral=True)
"Error: You do not have permission to use this command. "
"Only the bot owner can use the `logout` command. \n"
"https://http.cat/status/400", ephemeral=True)
# Handle command not found error
elif isinstance(error, app_commands.CommandNotFound):
await interaction.response.send_message(
Expand Down Expand Up @@ -857,8 +858,9 @@ async def logout_bot(self, interaction: discord.Interaction):
await self.bot.close()
else:
await interaction.response.send_message(
"Error: You do not have permission to use this command. Only the bot owner can use the `logout` command.",
ephemeral=True)
"Error: You do not have permission to use this command. "
"Only the bot owner can use the `logout` command. \n"
"https://http.cat/status/400", ephemeral=True)

# Task to send a random cake GIF every 24 hours
@tasks.loop(hours=24) # Run every 24 hours
Expand Down

0 comments on commit 843a362

Please sign in to comment.