summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorementalo <ementalo@e251c2fe-e539-e718-e476-b85c1f46cddb>2011-04-26 22:46:34 +0000
committerementalo <ementalo@e251c2fe-e539-e718-e476-b85c1f46cddb>2011-04-26 22:46:34 +0000
commitedc09047891d3e6f621b3958561fd82e3277b273 (patch)
tree1663b80551bfe98f7016b914aeea80f90774a455
parent63f2eb157a8e1b72b95317d644d95ea29f4a163a (diff)
downloadEssentials-edc09047891d3e6f621b3958561fd82e3277b273.tar
Essentials-edc09047891d3e6f621b3958561fd82e3277b273.tar.gz
Essentials-edc09047891d3e6f621b3958561fd82e3277b273.tar.lz
Essentials-edc09047891d3e6f621b3958561fd82e3277b273.tar.xz
Essentials-edc09047891d3e6f621b3958561fd82e3277b273.zip
[trunk] fix /weather and /thunder args
git-svn-id: https://svn.java.net/svn/essentials~svn/trunk@1281 e251c2fe-e539-e718-e476-b85c1f46cddb
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandthunder.java2
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/Commandweather.java7
2 files changed, 3 insertions, 6 deletions
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandthunder.java b/Essentials/src/com/earth2me/essentials/commands/Commandthunder.java
index a95475ef3..347c204a1 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandthunder.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandthunder.java
@@ -27,7 +27,7 @@ public class Commandthunder extends EssentialsCommand
user.charge(this);
World world = user.getWorld();
boolean setThunder = args[0].equalsIgnoreCase("true");
- if (!args[1].isEmpty() || args[1] != null)
+ if (args.length > 1)
{
world.setThundering(setThunder ? true : false);
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandweather.java b/Essentials/src/com/earth2me/essentials/commands/Commandweather.java
index d76807a3f..01348d99e 100644
--- a/Essentials/src/com/earth2me/essentials/commands/Commandweather.java
+++ b/Essentials/src/com/earth2me/essentials/commands/Commandweather.java
@@ -23,10 +23,10 @@ public class Commandweather extends EssentialsCommand
return;
}
- boolean isStorm = args[0].equalsIgnoreCase("storm");
+ boolean isStorm = args[0].equalsIgnoreCase("storm");
World world = user.getWorld();
user.charge(this);
- if (!args[1].isEmpty() || args[1] != null)
+ if (args.length > 1)
{
world.setStorm(isStorm ? true : false);
@@ -42,6 +42,3 @@ public class Commandweather extends EssentialsCommand
}
}
}
-
-
-