Check the player we are bringing has permission to enter the world vs the initiating user

This commit is contained in:
Paul A. 2012-08-01 15:53:30 +02:00
parent ab7a19b6e6
commit 1d92cb0e0a

View file

@ -31,7 +31,7 @@ public class Commandtpohere extends EssentialsCommand
}
if (user.getWorld() != player.getWorld() && ess.getSettings().isWorldTeleportPermissions()
&& !user.isAuthorized("essentials.world." + user.getWorld().getName()))
&& !player.isAuthorized("essentials.world." + user.getWorld().getName()))
{
throw new Exception(_("noPerm", "essentials.world." + user.getWorld().getName()));
}