reciple 1.5.1 → 1.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -124,13 +124,15 @@ class RecipleClient extends discord_js_1.Client {
|
|
|
124
124
|
|| (0, isIgnoredChannel_1.isIgnoredChannel)(message.channelId, this.config.ignoredChannels))
|
|
125
125
|
return;
|
|
126
126
|
const commandOptions = command.getCommandOptionValues(parseCommand);
|
|
127
|
-
if (
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
127
|
+
if (command.validateOptions) {
|
|
128
|
+
if (commandOptions.some(o => o.invalid)) {
|
|
129
|
+
yield message.reply(this.getMessage('invalidArguments', 'Invalid argument(s) given.'));
|
|
130
|
+
return;
|
|
131
|
+
}
|
|
132
|
+
if (commandOptions.some(o => o.missing)) {
|
|
133
|
+
yield message.reply(this.getMessage('notEnoughArguments', 'Not enough arguments.'));
|
|
134
|
+
return;
|
|
135
|
+
}
|
|
134
136
|
}
|
|
135
137
|
const options = {
|
|
136
138
|
message: message,
|