Change to String#equals

This commit is contained in:
KingRainbow44 2022-04-20 00:10:43 -04:00
parent c0155b8dcc
commit 7485e9fd4e
No known key found for this signature in database
GPG Key ID: FC2CB64B00D257BE

View File

@ -113,7 +113,7 @@ public final class CommandMap {
if(player != null) {
String permissionNode = this.annotations.get(label).permission();
Account account = player.getAccount();
if(!Objects.equals(permissionNode, "") && !account.hasPermission(permissionNode)) {
if(!permissionNode.equals("*") && !account.hasPermission(permissionNode)) {
CommandHandler.sendMessage(player, "You do not have permission to run this command."); return;
}
}