Permission System Improvements
This commit is contained in:
parent
3b8e54baec
commit
965911d3de
@ -110,14 +110,14 @@ public enum Perm implements Identified
|
|||||||
// HAS
|
// HAS
|
||||||
// -------------------------------------------- //
|
// -------------------------------------------- //
|
||||||
|
|
||||||
public boolean has(Permissible permissible, boolean informSenderIfNot)
|
public boolean has(Permissible permissible, boolean verboose)
|
||||||
{
|
{
|
||||||
return PermissionUtil.hasPermission(permissible, this.id, informSenderIfNot);
|
return PermissionUtil.hasPermission(permissible, this, verboose);
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean has(Permissible permissible)
|
public boolean has(Permissible permissible)
|
||||||
{
|
{
|
||||||
return has(permissible, false);
|
return PermissionUtil.hasPermission(permissible, this);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -544,8 +544,7 @@ public class MPlayer extends SenderEntity<MPlayer> implements EconomyParticipato
|
|||||||
if (this.overriding == null) return false;
|
if (this.overriding == null) return false;
|
||||||
if (this.overriding == false) return false;
|
if (this.overriding == false) return false;
|
||||||
|
|
||||||
// Deactivate admin mode if we don't have permissions for it.
|
if (!this.hasPermission(Perm.OVERRIDE, true))
|
||||||
if (this.getSender() != null && ! Perm.OVERRIDE.has(this.getSender(), false))
|
|
||||||
{
|
{
|
||||||
this.setOverriding(false);
|
this.setOverriding(false);
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
Reference in New Issue
Block a user