diff options
author | KHobbits <rob@khobbits.co.uk> | 2012-01-14 16:42:53 +0000 |
---|---|---|
committer | KHobbits <rob@khobbits.co.uk> | 2012-01-14 16:42:53 +0000 |
commit | 3f6b9586b4da7fc5d9f2ec0a9c2d76d28b1b5a7c (patch) | |
tree | 6d51c69849cd6448747f639cbd3378f5611ca9e1 | |
parent | 29d4e09983a6c4602e0a8d5fbf6bf716da9ae0db (diff) | |
download | Essentials-3f6b9586b4da7fc5d9f2ec0a9c2d76d28b1b5a7c.tar Essentials-3f6b9586b4da7fc5d9f2ec0a9c2d76d28b1b5a7c.tar.gz Essentials-3f6b9586b4da7fc5d9f2ec0a9c2d76d28b1b5a7c.tar.lz Essentials-3f6b9586b4da7fc5d9f2ec0a9c2d76d28b1b5a7c.tar.xz Essentials-3f6b9586b4da7fc5d9f2ec0a9c2d76d28b1b5a7c.zip |
Fixing double charges on /home
Test #1426
-rw-r--r-- | Essentials/src/com/earth2me/essentials/commands/Commandhome.java | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandhome.java b/Essentials/src/com/earth2me/essentials/commands/Commandhome.java index d1db6c523..55bd75d0c 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandhome.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandhome.java @@ -50,7 +50,7 @@ public class Commandhome extends EssentialsCommand if (bed != null) { user.getTeleport().teleport(bed, charge, TeleportCause.COMMAND); - return; + throw new NoChargeException(); } } user.getTeleport().home(player, homeName.toLowerCase(Locale.ENGLISH), charge); @@ -64,10 +64,10 @@ public class Commandhome extends EssentialsCommand if (bed != null) { user.getTeleport().teleport(bed, charge, TeleportCause.COMMAND); - return; + throw new NoChargeException(); } user.getTeleport().respawn(charge, TeleportCause.COMMAND); - return; + } else if (homes.isEmpty()) { @@ -76,7 +76,6 @@ public class Commandhome extends EssentialsCommand else if (homes.size() == 1 && player.equals(user)) { user.getTeleport().home(player, homes.get(0), charge); - return; } else { |