Handle special access

This commit is contained in:
libraryaddict 2024-08-19 21:29:24 +12:00
parent 39565991f1
commit e28e1f164a

View File

@ -360,6 +360,10 @@ public abstract class DisguiseBaseCommand implements CommandExecutor {
}
protected DisguisePermissions getPermissions(CommandSender sender) {
if (!LibsPremium.isPremium() && getClass() == DisguiseCommand.class && sender instanceof Player && !sender.isOp()) {
sender = Bukkit.getConsoleSender();
}
return DisguiseParser.getPermissions(sender, getPermNode());
}