refactor: replace console.* with logger in core lib files
Update loaders, handlers, and BotClient to use centralized logger: - CommandLoader.ts and EventLoader.ts - AutocompleteHandler.ts, CommandHandler.ts, ComponentInteractionHandler.ts - BotClient.ts Provides consistent formatting across all core library logging.
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import { ButtonInteraction, StringSelectMenuInteraction, ModalSubmitInteraction } from "discord.js";
|
||||
import { logger } from "@lib/logger";
|
||||
|
||||
type ComponentInteraction = ButtonInteraction | StringSelectMenuInteraction | ModalSubmitInteraction;
|
||||
|
||||
@@ -19,7 +20,7 @@ export class ComponentInteractionHandler {
|
||||
await handlerMethod(interaction);
|
||||
return;
|
||||
} else {
|
||||
console.error(`Handler method ${route.method} not found in module`);
|
||||
logger.error(`Handler method ${route.method} not found in module`);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user