[Bug] Last argument doesn't consume rest of input
As mentioned in the comments of #170 , the last argument doesn't consume the rest of the input. Example:
@CommandAlias("msg")
public void onDefault(CommandIssuer sender, String username, String message) {
AsyncDatabase.submit(() -> {
UUID playerUUID = PlayerManager.getUUIDForUsername(username);
if(!RedisManager.getPlayers().contains(playerUUID)){
sender.sendMessage("That player is not online.");
return;
}
});
}
You should find that message doesn't get set at all.
does it work if you use CommandSender instead of CommandISsuer?
It does indeed work fine when using CommandSender instead of CommandIssuer!
Is it possible to get this to work using CommandIssuer? We'd like to use CommandIssuer across commands instead.
I am super busy ATM, so PR's welcome if you can figure out what's wrong.
You can use getCurrentCommandIssuer() in the command in mean time to obtain it.