summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKHobbits <rob@khobbits.co.uk>2011-12-02 21:32:32 +0000
committerKHobbits <rob@khobbits.co.uk>2011-12-02 21:32:32 +0000
commit293e7b04a26026b5a7a5f59917795e1e61e77ac3 (patch)
tree4cc3f094a6fe13f579e5888d8b3a8fe2c6526e59
parent68c873ea0d0da42ddd3d7da756d948a02bc50214 (diff)
downloadEssentials-293e7b04a26026b5a7a5f59917795e1e61e77ac3.tar
Essentials-293e7b04a26026b5a7a5f59917795e1e61e77ac3.tar.gz
Essentials-293e7b04a26026b5a7a5f59917795e1e61e77ac3.tar.lz
Essentials-293e7b04a26026b5a7a5f59917795e1e61e77ac3.tar.xz
Essentials-293e7b04a26026b5a7a5f59917795e1e61e77ac3.zip
Patching gamemode and god toggles to not match on ' '
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandgamemode.java2
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandgod.java2
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;