diff options
author | ElgarL <ElgarL@palmergames.com> | 2011-10-01 11:22:19 +0100 |
---|---|---|
committer | ElgarL <ElgarL@palmergames.com> | 2011-10-01 11:22:19 +0100 |
commit | 0462026f332de2fd2d2bc442b222b91de5853c1a (patch) | |
tree | 8f270c354bb20847594428ec062211ae89740935 /EssentialsGroupManager/src/org/anjocaido | |
parent | ab67d0e2323cc332f0e863085774867cfe95dbdf (diff) | |
download | Essentials-0462026f332de2fd2d2bc442b222b91de5853c1a.tar Essentials-0462026f332de2fd2d2bc442b222b91de5853c1a.tar.gz Essentials-0462026f332de2fd2d2bc442b222b91de5853c1a.tar.lz Essentials-0462026f332de2fd2d2bc442b222b91de5853c1a.tar.xz Essentials-0462026f332de2fd2d2bc442b222b91de5853c1a.zip |
Fixed an issue with superperms where plugins define perms with
inheritance after the root perms
Diffstat (limited to 'EssentialsGroupManager/src/org/anjocaido')
-rw-r--r-- | EssentialsGroupManager/src/org/anjocaido/groupmanager/Tasks/BukkitPermsUpdateTask.java | 1 | ||||
-rw-r--r-- | EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java | 6 |
2 files changed, 4 insertions, 3 deletions
diff --git a/EssentialsGroupManager/src/org/anjocaido/groupmanager/Tasks/BukkitPermsUpdateTask.java b/EssentialsGroupManager/src/org/anjocaido/groupmanager/Tasks/BukkitPermsUpdateTask.java index 27951112d..f4b805c35 100644 --- a/EssentialsGroupManager/src/org/anjocaido/groupmanager/Tasks/BukkitPermsUpdateTask.java +++ b/EssentialsGroupManager/src/org/anjocaido/groupmanager/Tasks/BukkitPermsUpdateTask.java @@ -18,6 +18,7 @@ public class BukkitPermsUpdateTask implements Runnable { public void run() {
// Signal loaded and update BukkitPermissions.
GroupManager.setLoaded(true);
+ GroupManager.BukkitPermissions.collectPermissions();
GroupManager.BukkitPermissions.updateAllPlayers();
GroupManager.logger.info("Bukkit Permissions Updated!");
diff --git a/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java b/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java index 20f6331bc..b4035a1f5 100644 --- a/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java +++ b/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java @@ -93,7 +93,7 @@ public class BukkitPermissions { manager.registerEvent(Event.Type.PLUGIN_DISABLE, serverListener, Event.Priority.Normal, plugin);
}
- private void collectPermissions() {
+ public void collectPermissions() {
registeredPermissions.clear();
for (Plugin bukkitPlugin : Bukkit.getServer().getPluginManager().getPlugins()) {
for(Permission permission : bukkitPlugin.getDescription().getPermissions())
@@ -134,8 +134,8 @@ public class BukkitPermissions { Boolean value;
for (Permission permission : registeredPermissions) {
value = worldData.getPermissionsHandler().checkUserPermission(user, permission.getName());
-
- attachment.setPermission(permission, value);
+ if (value == true)
+ attachment.setPermission(permission, value);
}
// Add any missing permissions for this player (non bukkit plugins)
|