diff options
author | KHobbits <rob@khobbits.co.uk> | 2014-04-24 10:24:35 +0100 |
---|---|---|
committer | KHobbits <rob@khobbits.co.uk> | 2014-04-24 10:24:35 +0100 |
commit | 8a60f59433dfd1b86c190b50ad35d953b9c74a60 (patch) | |
tree | 3cfa5a125d776503feed176a455262ce8a503fe5 | |
parent | 36594b6311e0d73dec40d649449a280264b2f79a (diff) | |
download | Essentials-8a60f59433dfd1b86c190b50ad35d953b9c74a60.tar Essentials-8a60f59433dfd1b86c190b50ad35d953b9c74a60.tar.gz Essentials-8a60f59433dfd1b86c190b50ad35d953b9c74a60.tar.lz Essentials-8a60f59433dfd1b86c190b50ad35d953b9c74a60.tar.xz Essentials-8a60f59433dfd1b86c190b50ad35d953b9c74a60.zip |
Fix time command exit statuses.
-rw-r--r-- | Essentials/src/com/earth2me/essentials/commands/Commandtime.java | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandtime.java b/Essentials/src/com/earth2me/essentials/commands/Commandtime.java index 4768a3089..2d456073a 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandtime.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandtime.java @@ -56,7 +56,7 @@ public class Commandtime extends EssentialsCommand else { getWorldsTime(sender, worlds); - return; + throw new NoChargeException(); } } else @@ -67,8 +67,7 @@ public class Commandtime extends EssentialsCommand final User user = ess.getUser(sender.getPlayer()); if (user != null && !user.isAuthorized("essentials.time.set")) { - user.sendMessage(tl("timeSetPermission")); - return; + throw new Exception(tl("timeSetPermission")); } // Parse the target time int ticks from args[0] @@ -185,4 +184,4 @@ class WorldNameComparator implements Comparator<World> { return a.getName().compareTo(b.getName()); } -}
\ No newline at end of file +} |