Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 9 additions & 6 deletions modules/administration/botinfo.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

import discord
import git
from discord.ext import commands
from discord import app_commands

from core import auxiliary, cogs

Expand All @@ -36,15 +36,18 @@ class BotInfo(cogs.BaseCog):
The class that holds the bot command
"""

@commands.check(auxiliary.bot_admin_check_context)
@commands.command(name="bot", description="Provides bot info")
async def get_bot_data(self: Self, ctx: commands.Context) -> None:
@app_commands.check(auxiliary.bot_admin_check_interaction)
@app_commands.command(
name="bot",
description="Provides bot info",
)
async def get_bot_data(self: Self, interaction: discord.Interaction) -> None:
"""Gets various data about the bot.

This is a command and should be accessed via Discord.

Args:
ctx (commands.Context): the context object for the calling message
interaction (discord.Interaction): the interaction that called this command
"""
embed = discord.Embed(title=self.bot.user.name, color=discord.Color.blurple())

Expand Down Expand Up @@ -122,4 +125,4 @@ async def get_bot_data(self: Self, ctx: commands.Context) -> None:

embed.set_thumbnail(url=self.bot.user.display_avatar.url)

await ctx.send(embed=embed)
await interaction.response.send_message(embed=embed)
Loading