Fix negating group permissions to cancel inheritance

This commit is contained in:
Luck 2017-08-13 19:40:59 +02:00
parent a40421fa1f
commit c598daf350
No known key found for this signature in database
GPG Key ID: EFA9B3EC5FD90F8B

View File

@ -533,7 +533,7 @@ public abstract class PermissionHolder {
if (!n.isGroupNode()) continue;
String groupName = n.getGroupName();
if (!processedGroups.add(groupName) || excludedGroups.contains(groupName)) continue;
if (!processedGroups.add(groupName) || excludedGroups.contains(groupName) || !n.getValue()) continue;
if (!((contexts.isApplyGlobalGroups() || n.isServerSpecific()) && (contexts.isApplyGlobalWorldGroups() || n.isWorldSpecific()))) {
continue;
@ -611,7 +611,7 @@ public abstract class PermissionHolder {
if (!n.isGroupNode()) continue;
String groupName = n.getGroupName();
if (!processedGroups.add(groupName) || excludedGroups.contains(groupName)) continue;
if (!processedGroups.add(groupName) || excludedGroups.contains(groupName) || !n.getValue()) continue;
Group g = plugin.getGroupManager().getIfLoaded(groupName);
if (g != null) {
@ -759,7 +759,7 @@ public abstract class PermissionHolder {
if (!n.isGroupNode()) continue;
String groupName = n.getGroupName();
if (!processedGroups.add(groupName) || excludedGroups.contains(groupName)) continue;
if (!processedGroups.add(groupName) || excludedGroups.contains(groupName) || !n.getValue()) continue;
if (!((contexts.isApplyGlobalGroups() || n.isServerSpecific()) && (contexts.isApplyGlobalWorldGroups() || n.isWorldSpecific()))) {
continue;
@ -819,7 +819,7 @@ public abstract class PermissionHolder {
if (!n.isGroupNode()) continue;
String groupName = n.getGroupName();
if (!processedGroups.add(groupName) || excludedGroups.contains(groupName)) continue;
if (!processedGroups.add(groupName) || excludedGroups.contains(groupName) || !n.getValue()) continue;
Group g = plugin.getGroupManager().getIfLoaded(groupName);
if (g != null) {