summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--EssentialsGroupManager/src/Changelog.txt3
-rw-r--r--EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java7
2 files changed, 7 insertions, 3 deletions
diff --git a/EssentialsGroupManager/src/Changelog.txt b/EssentialsGroupManager/src/Changelog.txt
index 75d506396..64c9d98b3 100644
--- a/EssentialsGroupManager/src/Changelog.txt
+++ b/EssentialsGroupManager/src/Changelog.txt
@@ -217,4 +217,5 @@ v 2.0:
- '/manselect' will no longer list duplicate worlds.
- Added a new mirroring option in the config of 'all_unnamed_worlds'. This will cause all new or unnamed worlds to use this mirroring.
- Don't allow adding a node with '/manuaddp' and '/mangaddp' which is already negated.
- - Warn when adding a node where an exception already exist. \ No newline at end of file
+ - Warn when adding a node where an exception already exist.
+ - Only prevent adding nodes with '/manuaddp' and '/mangaddp' if they are exact matches (not wildcards). \ No newline at end of file
diff --git a/EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java b/EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java
index 74d39ecae..fbe0378d6 100644
--- a/EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java
+++ b/EssentialsGroupManager/src/org/anjocaido/groupmanager/GroupManager.java
@@ -770,7 +770,8 @@ public class GroupManager extends JavaPlugin {
} else if (permissionResult.resultType.equals(PermissionCheckResult.Type.FOUND)) {
sender.sendMessage(ChatColor.RED + "The user already has direct access to that permission.");
sender.sendMessage(ChatColor.RED + "Node: " + permissionResult.accessLevel);
- return true;
+ if (permissionResult.accessLevel.equalsIgnoreCase(args[1]));
+ return true;
} else if (permissionResult.resultType.equals(PermissionCheckResult.Type.NEGATION)) {
// Warn only while still allowing you to add the node.
sender.sendMessage(ChatColor.RED + "The user already has a matching Negated node.");
@@ -1026,7 +1027,9 @@ public class GroupManager extends JavaPlugin {
} else if (permissionResult.resultType.equals(PermissionCheckResult.Type.FOUND)) {
sender.sendMessage(ChatColor.RED + "The group already has direct access to that permission.");
sender.sendMessage(ChatColor.RED + "Node: " + permissionResult.accessLevel);
- return true;
+ // Abort adding if the node is a direct match.
+ if (permissionResult.accessLevel.equalsIgnoreCase(args[1]));
+ return true;
} else if (permissionResult.resultType.equals(PermissionCheckResult.Type.NEGATION)) {
// Warn only while still allowing you to add the node.
sender.sendMessage(ChatColor.RED + "The group already has a matching Negated node.");