#5 replace all console.logs with debugger
All checks were successful
DRB Tests / drb_mocha_tests (pull_request) Successful in 32s
All checks were successful
DRB Tests / drb_mocha_tests (pull_request) Successful in 32s
This commit is contained in:
@@ -1,14 +1,16 @@
|
||||
import { DebugBuilder } from "../../modules/debugger.mjs";
|
||||
const log = new DebugBuilder("server", "discordBot.events.interactionCreate");
|
||||
import { Events } from 'discord.js';
|
||||
|
||||
export const name = Events.InteractionCreate;
|
||||
|
||||
export async function execute(nodeIo, interaction) {
|
||||
const command = interaction.client.commands.get(interaction.commandName);
|
||||
console.log("Interaction created for command: ", command);
|
||||
log.INFO("Interaction created for command: ", command);
|
||||
|
||||
// Execute autocomplete if the user is checking autocomplete
|
||||
if (interaction.isAutocomplete()) {
|
||||
console.log("Running autocomplete for command: ", command.data.name);
|
||||
log.INFO("Running autocomplete for command: ", command.data.name);
|
||||
return await command.autocomplete(nodeIo, interaction);
|
||||
}
|
||||
|
||||
@@ -20,7 +22,7 @@ export async function execute(nodeIo, interaction) {
|
||||
return;
|
||||
}
|
||||
|
||||
console.log(`${interaction.member.user} is running '${interaction.commandName}'`);
|
||||
log.INFO(`${interaction.member.user} is running '${interaction.commandName}'`);
|
||||
|
||||
// Defer the initial reply if the command has the parameter set
|
||||
if (command.deferInitialReply) {
|
||||
|
||||
Reference in New Issue
Block a user