added anon report
This commit is contained in:
@ -30,6 +30,17 @@ class Nessa(discord.Client):
|
|||||||
await self.close()
|
await self.close()
|
||||||
else:
|
else:
|
||||||
await interaction.response.send_message("Hey! I don't know you! You don't have permission to use this command. Only the owner can do that.", ephemeral=True)
|
await interaction.response.send_message("Hey! I don't know you! You don't have permission to use this command. Only the owner can do that.", ephemeral=True)
|
||||||
|
|
||||||
|
@self.tree.command(name="report_issue", description="Send an anonymous issue report.")
|
||||||
|
async def report_issue(interaction: discord.Interaction, message: str):
|
||||||
|
# Your Discord user ID
|
||||||
|
your_user_id = OWNER_ID
|
||||||
|
# Fetch your user object using your ID
|
||||||
|
owner = await bot.fetch_user(your_user_id)
|
||||||
|
# Send the DM to you
|
||||||
|
await owner.send(f"Hey Chief, I got a report for you: {message}")
|
||||||
|
# Respond to the user to confirm the message has been sent
|
||||||
|
await interaction.response.send_message("I've passed on your issue to the Chief!", ephemeral=True)
|
||||||
|
|
||||||
async def on_ready(self):
|
async def on_ready(self):
|
||||||
print(f"Logged on as {self.user}!")
|
print(f"Logged on as {self.user}!")
|
||||||
|
Reference in New Issue
Block a user