mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-26 14:19:11 +02:00
Fix
This commit is contained in:
@@ -27,7 +27,7 @@ module.exports = class CommandDispatcher {
|
|||||||
const command = this.resolveCommand(matched[2].toLowerCase());
|
const command = this.resolveCommand(matched[2].toLowerCase());
|
||||||
if (!command) {
|
if (!command) {
|
||||||
return {
|
return {
|
||||||
command: this.registry.commands.find(cmd => cmd.unknown),
|
command: this.client.registry.commands.find(cmd => cmd.unknown),
|
||||||
args: { command: command[2].toLowerCase() }
|
args: { command: command[2].toLowerCase() }
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
@@ -54,6 +54,6 @@ module.exports = class CommandDispatcher {
|
|||||||
}
|
}
|
||||||
|
|
||||||
resolveCommand(command) {
|
resolveCommand(command) {
|
||||||
return this.registry.commands.find(cmd => cmd.name === command || cmd.aliases.includes(command));
|
return this.client.registry.commands.find(cmd => cmd.name === command || cmd.aliases.includes(command));
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user