I didnt save the import 😭

This commit is contained in:
MrMasrozYTLIVE 2024-07-12 23:01:06 +03:00
parent 31a8fedf2d
commit 758be94728

View File

@ -377,7 +377,7 @@ export class Client extends TypedEventEmitter<LinkUpEvents> {
const commands = await promisify(glob)(normalize(path + "/**/*.{ts,js}"));
for (const commandPath of commands) {
try {
let command: MaybeCommand = await require(commandPath);
let command: MaybeCommand = await import(commandPath);
if ('default' in command) command = command.default;
if (command.constructor.name === 'Object') command = Object.values(command)[0];