1
0
mirror of https://github.com/essentials/Essentials.git synced 2025-09-19 02:42:12 +02:00

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

This commit is contained in:
Paul A.
2012-08-01 16:04:13 +02:00
parent 519f8a7f88
commit fd3d52f324

View File

@@ -58,7 +58,7 @@ public class Commandtp extends EssentialsCommand
throw new Exception(_("teleportDisabled", toPlayer.getDisplayName()));
}
if (target.getWorld() != toPlayer.getWorld() && ess.getSettings().isWorldTeleportPermissions()
&& !player.isAuthorized("essentials.world." + toPlayer.getWorld().getName()))
&& !target.isAuthorized("essentials.world." + toPlayer.getWorld().getName()))
{
throw new Exception(_("noPerm", "essentials.world." + toPlayer.getWorld().getName()));
}