diff options
author | ElgarL <ElgarL@palmergames.com> | 2012-01-25 22:35:24 +0000 |
---|---|---|
committer | ElgarL <ElgarL@palmergames.com> | 2012-01-25 22:35:24 +0000 |
commit | e563405a7dcd462d6bae00189c89dd789509c8e0 (patch) | |
tree | ebed0424bf98c0a37a1a3d3527e4ca068ced7847 /EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions | |
parent | ae2cf3d95c752b78408b58af7cce11575d210230 (diff) | |
download | Essentials-e563405a7dcd462d6bae00189c89dd789509c8e0.tar Essentials-e563405a7dcd462d6bae00189c89dd789509c8e0.tar.gz Essentials-e563405a7dcd462d6bae00189c89dd789509c8e0.tar.lz Essentials-e563405a7dcd462d6bae00189c89dd789509c8e0.tar.xz Essentials-e563405a7dcd462d6bae00189c89dd789509c8e0.zip |
Check for a null player object in the PlayerTeleportEvent.
Diffstat (limited to 'EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions')
-rw-r--r-- | EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java b/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java index 481779c3c..3ab2dbbeb 100644 --- a/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java +++ b/EssentialsGroupManager/src/org/anjocaido/groupmanager/permissions/BukkitPermissions.java @@ -397,7 +397,7 @@ public class BukkitPermissions { @EventHandler(priority = EventPriority.LOWEST)
public void onPlayerTeleport(PlayerTeleportEvent event) { // can be teleported into another world
- if ((event.getTo() != null) && (!event.getFrom().getWorld().equals(event.getTo().getWorld()))) { // only if world actually changed
+ if ((event.getTo() != null) && (event.getPlayer() != null) && (!event.getFrom().getWorld().equals(event.getTo().getWorld()))) { // only if world actually changed
updatePermissions(event.getPlayer(), event.getTo().getWorld().getName());
}
}
|