diff options
author | KHobbits <rob@khobbits.co.uk> | 2013-07-09 09:08:26 +0100 |
---|---|---|
committer | KHobbits <rob@khobbits.co.uk> | 2013-07-09 09:08:26 +0100 |
commit | 504728b46b4f9e2834670b41fafb4fe98ed2164c (patch) | |
tree | 4df9c3d989f0691850219719584951651359edf0 | |
parent | 84bd137b9f102692da870bcec53255a0342e758e (diff) | |
download | Essentials-504728b46b4f9e2834670b41fafb4fe98ed2164c.tar Essentials-504728b46b4f9e2834670b41fafb4fe98ed2164c.tar.gz Essentials-504728b46b4f9e2834670b41fafb4fe98ed2164c.tar.lz Essentials-504728b46b4f9e2834670b41fafb4fe98ed2164c.tar.xz Essentials-504728b46b4f9e2834670b41fafb4fe98ed2164c.zip |
Fix user comparison.
6 files changed, 6 insertions, 6 deletions
diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandfly.java b/Essentials/src/com/earth2me/essentials/commands/Commandfly.java index d419d78d1..43b40a780 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandfly.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandfly.java @@ -60,7 +60,7 @@ public class Commandfly extends EssentialsToggleCommand } user.sendMessage(_("flyMode", _(enabled ? "enabled" : "disabled"), user.getDisplayName())); - if (!sender.equals(user)) + if (!sender.equals(user.getBase())) { sender.sendMessage(_("flyMode", _(enabled ? "enabled" : "disabled"), user.getDisplayName())); } diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandgod.java b/Essentials/src/com/earth2me/essentials/commands/Commandgod.java index 60acb0fbf..1c5352319 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandgod.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandgod.java @@ -61,7 +61,7 @@ public class Commandgod extends EssentialsToggleCommand } user.sendMessage(_("godMode", enabled ? _("enabled") : _("disabled"))); - if (!sender.equals(user)) + if (!sender.equals(user.getBase())) { sender.sendMessage(_("godMode", _(enabled ? "godEnabledFor" : "godDisabledFor", user.getDisplayName()))); } diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandsocialspy.java b/Essentials/src/com/earth2me/essentials/commands/Commandsocialspy.java index ccdb242e0..7259ae7cc 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandsocialspy.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandsocialspy.java @@ -56,7 +56,7 @@ public class Commandsocialspy extends EssentialsToggleCommand user.sendMessage(_("socialSpy", user.getDisplayName(), enabled ? _("enabled") : _("disabled"))); - if (!sender.equals(user)) + if (!sender.equals(user.getBase())) { sender.sendMessage(_("socialSpy", user.getDisplayName(), enabled ? _("enabled") : _("disabled"))); } diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandtpaall.java b/Essentials/src/com/earth2me/essentials/commands/Commandtpaall.java index 41d503318..03672ddd5 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandtpaall.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandtpaall.java @@ -45,7 +45,7 @@ public class Commandtpaall extends EssentialsCommand { continue; } - if (target.equals(sender) + if (sender.equals(target.getBase()) && target.getWorld() != player.getWorld() && ess.getSettings().isWorldTeleportPermissions() && !target.isAuthorized("essentials.worlds." + target.getWorld().getName())) { diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandtpall.java b/Essentials/src/com/earth2me/essentials/commands/Commandtpall.java index 4b3dd2783..1b9ca7553 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandtpall.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandtpall.java @@ -42,7 +42,7 @@ public class Commandtpall extends EssentialsCommand { continue; } - if (target.equals(sender) + if (sender.equals(target.getBase()) && target.getWorld() != player.getWorld() && ess.getSettings().isWorldTeleportPermissions() && !target.isAuthorized("essentials.worlds." + target.getWorld().getName())) { diff --git a/Essentials/src/com/earth2me/essentials/commands/Commandtptoggle.java b/Essentials/src/com/earth2me/essentials/commands/Commandtptoggle.java index c9e5ca94a..7d8028353 100644 --- a/Essentials/src/com/earth2me/essentials/commands/Commandtptoggle.java +++ b/Essentials/src/com/earth2me/essentials/commands/Commandtptoggle.java @@ -55,7 +55,7 @@ public class Commandtptoggle extends EssentialsToggleCommand user.setTeleportEnabled(enabled); user.sendMessage(enabled ? _("teleportationEnabled") : _("teleportationDisabled")); - if (!sender.equals(user)) + if (!sender.equals(user.getBase())) { sender.sendMessage(enabled ? _("teleportationEnabledFor", user.getDisplayName()) : _("teleportationDisabledFor", user.getDisplayName())); } |