Fixed flag returning an error on a nonexistent flag

This commit is contained in:
TheEssem 2021-05-06 15:17:34 -05:00
parent 108afc3626
commit 11ab4ad1d4
2 changed files with 4 additions and 4 deletions

View file

@ -33,7 +33,7 @@ class ImageCommand extends Command {
]
};*/
criteria() {
async criteria() {
return true;
}
@ -70,7 +70,7 @@ class ImageCommand extends Command {
}
if (this.constructor.requiresText) {
if (this.args.length === 0 || !this.criteria(this.args)) {
if (this.args.length === 0 || !await this.criteria(this.args)) {
collections.runningCommands.delete(this.message.author.id);
return `${this.message.author.mention}, ${this.constructor.noText}`;
}