mirror of
https://github.com/EssentialsX/Essentials.git
synced 2024-12-25 02:27:33 +01:00
Fix banning random player (and all other commands where a empty player is given)
This commit is contained in:
parent
b21b7b7e15
commit
c70700f7b8
@ -47,6 +47,10 @@ public abstract class EssentialsCommand implements IEssentialsCommand
|
||||
{
|
||||
throw new NotEnoughArgumentsException();
|
||||
}
|
||||
if (args[0].isEmpty())
|
||||
{
|
||||
throw new NoSuchFieldException(_("playerNotFound"));
|
||||
}
|
||||
final User user = ess.getUser(args[pos]);
|
||||
if (user != null)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user