mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2024-11-25 12:25:46 +01:00
Send usage for '/p v' for too many arguments
This commit is contained in:
parent
a83a79c17e
commit
1e41734826
@ -182,6 +182,11 @@ public class Visit extends Command {
|
|||||||
final RunnableVal3<Command, Runnable, Runnable> confirm,
|
final RunnableVal3<Command, Runnable, Runnable> confirm,
|
||||||
final RunnableVal2<Command, CommandResult> whenDone
|
final RunnableVal2<Command, CommandResult> whenDone
|
||||||
) throws CommandException {
|
) throws CommandException {
|
||||||
|
if (args.length > 3) {
|
||||||
|
sendUsage(player);
|
||||||
|
return CompletableFuture.completedFuture(false);
|
||||||
|
}
|
||||||
|
|
||||||
if (args.length == 1 && args[0].contains(":")) {
|
if (args.length == 1 && args[0].contains(":")) {
|
||||||
args = args[0].split(":");
|
args = args[0].split(":");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user