summaryrefslogtreecommitdiffstats
path: root/EssentialsGroupManager/src/org/anjocaido/groupmanager
diff options
context:
space:
mode:
authorElgarL <ElgarL@palmergames.com>2012-04-03 14:30:27 +0100
committerElgarL <ElgarL@palmergames.com>2012-04-03 14:30:27 +0100
commit183602ac28d1e195cdd71e17dc5fc26f70f3a074 (patch)
treeef25025bffc3015d1ad24bf3ad875d6542d4af80 /EssentialsGroupManager/src/org/anjocaido/groupmanager
parente2e51c9c95f95906ad370bee7bcf698918b9a20b (diff)
downloadEssentials-183602ac28d1e195cdd71e17dc5fc26f70f3a074.tar
Essentials-183602ac28d1e195cdd71e17dc5fc26f70f3a074.tar.gz
Essentials-183602ac28d1e195cdd71e17dc5fc26f70f3a074.tar.lz
Essentials-183602ac28d1e195cdd71e17dc5fc26f70f3a074.tar.xz
Essentials-183602ac28d1e195cdd71e17dc5fc26f70f3a074.zip
Prevent Null entries in group inheritance from throwing errors.
Diffstat (limited to 'EssentialsGroupManager/src/org/anjocaido/groupmanager')
-rw-r--r--EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java10
1 files changed, 6 insertions, 4 deletions
diff --git a/EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java b/EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java
index d7f146438..cee2ec0b8 100644
--- a/EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java
+++ b/EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java
@@ -563,10 +563,12 @@ public class WorldDataHolder {
List<String> inheritedList = inheritance.get(groupKey);
Group thisGroup = ph.getGroup(groupKey);
for (String inheritedKey : inheritedList) {
- Group inheritedGroup = ph.getGroup(inheritedKey);
- if (thisGroup != null && inheritedGroup != null) {
- thisGroup.addInherits(inheritedGroup);
- }
+ if (inheritedKey != null) {
+ Group inheritedGroup = ph.getGroup(inheritedKey);
+ if (thisGroup != null && inheritedGroup != null) {
+ thisGroup.addInherits(inheritedGroup);
+ }
+ }
}
}