diff options
author | ElgarL <ElgarL@Palmergames.com> | 2014-04-14 23:40:04 +0100 |
---|---|---|
committer | KHobbits <rob@khobbits.co.uk> | 2014-05-04 12:50:20 +0100 |
commit | aae586f79ac177734eefac9e786dc5fc50dabb43 (patch) | |
tree | 2be8507791fca5e465c43c3126be6f3086fce5c7 /EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java | |
parent | 32f49350cf7629b741539bdc4c68e7edce78f171 (diff) | |
download | Essentials-aae586f79ac177734eefac9e786dc5fc50dabb43.tar Essentials-aae586f79ac177734eefac9e786dc5fc50dabb43.tar.gz Essentials-aae586f79ac177734eefac9e786dc5fc50dabb43.tar.lz Essentials-aae586f79ac177734eefac9e786dc5fc50dabb43.tar.xz Essentials-aae586f79ac177734eefac9e786dc5fc50dabb43.zip |
Fix overloadedWorldHolder so it correctly calls the new WorldHolder code when the user is not overloaded.
Diffstat (limited to 'EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java')
-rw-r--r-- | EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java b/EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java index 75d8ed570..14a9a052d 100644 --- a/EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java +++ b/EssentialsGroupManager/src/org/anjocaido/groupmanager/dataholder/WorldDataHolder.java @@ -119,8 +119,9 @@ public class WorldDataHolder { // Search for a LastName match for (User user : getUserList()) { - if (user.getLastName().equalsIgnoreCase(userId)) + if (user.getLastName().equalsIgnoreCase(userId)) { return user; + } } } @@ -157,14 +158,13 @@ public class WorldDataHolder { if (usr.getLastName().equalsIgnoreCase(currentName)) { // Clone this user so we can set it's uUID - user = usr.clone(uUID); + user = usr.clone(uUID, currentName); // Delete it and replace with the new clone. this.removeUser(usr.getUUID()); - user.setLastName(currentName); this.addUser(user); - return user; + return getUsers().get(uUID.toLowerCase()); } } |