summaryrefslogtreecommitdiffstats
path: root/EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java
diff options
context:
space:
mode:
authorElgarL <ElgarL@palmergames.com>2011-10-31 17:23:24 +0000
committerElgarL <ElgarL@palmergames.com>2011-10-31 17:23:24 +0000
commit2e24240c498eb178ca009d11db3b60ec7fb34a44 (patch)
tree6aa208ade13d346e7d1c7cadcfc45e6ab4ede59e /EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java
parent1d477d84142788119d03f29db35df5c7a2b3b382 (diff)
downloadEssentials-2e24240c498eb178ca009d11db3b60ec7fb34a44.tar
Essentials-2e24240c498eb178ca009d11db3b60ec7fb34a44.tar.gz
Essentials-2e24240c498eb178ca009d11db3b60ec7fb34a44.tar.lz
Essentials-2e24240c498eb178ca009d11db3b60ec7fb34a44.tar.xz
Essentials-2e24240c498eb178ca009d11db3b60ec7fb34a44.zip
Added Info node support to Global Groups.
Diffstat (limited to 'EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java')
-rw-r--r--EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java b/EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java
index c8aa15cec..a9f7e3f6e 100644
--- a/EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java
+++ b/EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java
@@ -207,6 +207,11 @@ public class WorldDataHolder {
* @param groupToAdd
*/
public void addGroup(Group groupToAdd) {
+ if (groupToAdd.getName().startsWith("g:")) {
+ GroupManager.getGlobalGroups().addGroup(groupToAdd);
+ return;
+ }
+
if (groupToAdd.getDataSource() != this) {
groupToAdd = groupToAdd.clone(this);
}
@@ -263,7 +268,7 @@ public class WorldDataHolder {
public Group createGroup(String groupName) {
if (groupName.startsWith("g:")) {
Group newGroup = new Group(groupName);
- return GroupManager.getGlobalGroups().addGroup(newGroup);
+ return GroupManager.getGlobalGroups().newGroup(newGroup);
}
if (this.groups.containsKey(groupName.toLowerCase())) {