Fix OOB exception in ServerCommand when the command is just a space (#355)

This commit is contained in:
OptimisticDev 2024-08-01 08:36:15 +00:00 committed by GitHub
parent 923a64c906
commit 6fc8d1117c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -62,6 +62,11 @@ public final class ServerCommand implements Listener {
}
final String[] arr = command.split(" ");
if (arr.length == 0) {
return command;
}
String commandName = arr[0].toLowerCase();
if (isConsoleCommand) {