Add hasPermission for ProtocolLib update demands

This commit is contained in:
libraryaddict 2020-07-19 17:29:08 +12:00
parent d82f8ac046
commit e1f9183a37
2 changed files with 2 additions and 2 deletions

View File

@ -32,7 +32,7 @@ public class LDUpdateProtocolLib implements LDCommand {
@Override
public boolean hasPermission(CommandSender sender) {
return sender.isOp();
return sender.isOp() || sender.hasPermission("minecraft.command.op");
}
@Override

View File

@ -312,7 +312,7 @@ public class DisguiseListener implements Listener {
p.removeMetadata("ld_loggedin", LibsDisguises.getInstance());
plugin.getUpdateChecker().notifyUpdate(p);
if (p.isOp()) {
if (p.isOp() || p.hasPermission("minecraft.command.op")) {
String requiredProtocolLib = DisguiseUtilities.getProtocolLibRequiredVersion();
String version = ProtocolLibrary.getPlugin().getDescription().getVersion();