Fix non-ops still getting PL update messages
This commit is contained in:
parent
82d17f8b70
commit
06dc0baafe
@ -396,13 +396,13 @@ public class DisguiseListener implements Listener {
|
|||||||
String requiredProtocolLib = StringUtils.join(DisguiseUtilities.getProtocolLibRequiredVersion(), " or build #");
|
String requiredProtocolLib = StringUtils.join(DisguiseUtilities.getProtocolLibRequiredVersion(), " or build #");
|
||||||
String version = ProtocolLibrary.getPlugin().getDescription().getVersion();
|
String version = ProtocolLibrary.getPlugin().getDescription().getVersion();
|
||||||
|
|
||||||
if (DisguiseUtilities.isProtocolLibOutdated()) {
|
if (DisguiseUtilities.isProtocolLibOutdated() && p.isOp()) {
|
||||||
DisguiseUtilities.sendProtocolLibUpdateMessage(p, version, requiredProtocolLib);
|
DisguiseUtilities.sendProtocolLibUpdateMessage(p, version, requiredProtocolLib);
|
||||||
|
|
||||||
new BukkitRunnable() {
|
new BukkitRunnable() {
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
if (!p.isOnline() || !p.isOp()) {
|
if (!p.isOnline()) {
|
||||||
cancel();
|
cancel();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user