diff options
author | KHobbits <rob@khobbits.co.uk> | 2011-12-02 21:32:32 +0000 |
---|---|---|
committer | KHobbits <rob@khobbits.co.uk> | 2011-12-02 21:32:32 +0000 |
commit | b03a327f9bda21173fc78d4accf4d92fe9bcc90b (patch) | |
tree | 04f341b4a9b8c4d233ce67badac959cfdaa8d920 | |
parent | 3b2403b686ca3481d4dc2eed63e2753cc26280ce (diff) | |
download | Essentials-b03a327f9bda21173fc78d4accf4d92fe9bcc90b.tar Essentials-b03a327f9bda21173fc78d4accf4d92fe9bcc90b.tar.gz Essentials-b03a327f9bda21173fc78d4accf4d92fe9bcc90b.tar.lz Essentials-b03a327f9bda21173fc78d4accf4d92fe9bcc90b.tar.xz Essentials-b03a327f9bda21173fc78d4accf4d92fe9bcc90b.zip |
Patching gamemode and god toggles to not match on ' '
-rw-r--r-- | Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java | 2 | ||||
-rw-r--r-- | Essentials/src/com/earth2me/essentials/commands/Commandgod.java | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java b/Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java index 821692464..62ace9357 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java @@ -30,7 +30,7 @@ public class Commandgamemode extends EssentialsCommand @Override protected void run(final Server server, final User user, final String commandLabel, final String[] args) throws Exception { - if (args.length > 0 && user.isAuthorized("essentials.gamemode.others")) + if (args.length > 0 && !args[0].trim().isEmpty() && user.isAuthorized("essentials.gamemode.others")) { gamemodeOtherPlayers(server, user, args[0]); return; diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandgod.java b/Essentials/src/com/earth2me/essentials/commands/Commandgod.java index 9506e48b5..4d5bd424b 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandgod.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandgod.java @@ -28,7 +28,7 @@ public class Commandgod extends EssentialsCommand @Override protected void run(final Server server, final User user, final String commandLabel, final String[] args) throws Exception { - if (args.length > 0 && user.isAuthorized("essentials.god.others")) + if (args.length > 0 && !args[0].trim().isEmpty() && user.isAuthorized("essentials.god.others")) { godOtherPlayers(server, user, args[0]); return; |