Console Log every Command

This commit is contained in:
2024-04-07 12:44:16 +02:00
parent ac6834e467
commit cf500abfa9

View File

@@ -9,10 +9,13 @@ export default async (client: Client<true>, interaction: Interaction) => {
const localCommands = await getLocalCommands() as CommandInterface[]; const localCommands = await getLocalCommands() as CommandInterface[];
try { try {
const commandObject = localCommands.find((cmd) => cmd.name == interaction.commandName); const commandObject = localCommands.find((cmd) => cmd.name == interaction.commandName);
if(!commandObject) return; if(!commandObject) return;
console.log(`/${interaction.commandName} wurde von ${interaction.user.username} ausgeführt!`)
if(commandObject.devOnly){ if(commandObject.devOnly){
if(!devs.includes(interaction.user.id)) { if(!devs.includes(interaction.user.id)) {
interaction.reply({ interaction.reply({