mirror of
https://github.com/arthur-pbty/flint.git
synced 2026-08-07 04:31:04 +02:00
feat: ajouter la gestion des erreurs pour trop d'arguments et mise à jour des commandes
This commit is contained in:
@@ -59,6 +59,16 @@ export const parsePrefixArgs = async (
|
||||
errors.push(parsed.error);
|
||||
}
|
||||
|
||||
if (tokens.length > 0) {
|
||||
errors.push({
|
||||
key: "errors.args.tooMany",
|
||||
vars: {
|
||||
count: tokens.length,
|
||||
extras: tokens.join(" "),
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
return { values, errors };
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user