mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-03 23:36:43 +02:00
Fix
This commit is contained in:
@@ -25,7 +25,7 @@ module.exports = class CommandDispatcher {
|
||||
}
|
||||
|
||||
isPatternCommand(msg) {
|
||||
const patternCommands = this.commands
|
||||
const patternCommands = this.client.registry.commands
|
||||
.filter(cmd => cmd.patterns.length && cmd.patterns.some(pattern => pattern.test(msg.content)));
|
||||
if (!patternCommands.size) return false;
|
||||
return patternCommands.first();
|
||||
|
||||
Reference in New Issue
Block a user