When a variable can be null, check it before using it. Fixes #1308.

This commit is contained in:
Glitchfinder 2013-08-01 08:47:14 -07:00
parent 7479a02220
commit b1fc72e8a9

View File

@ -82,7 +82,13 @@ public class PlayerListener implements Listener {
return; return;
} }
UserManager.getPlayer(player).actualizeTeleportATS(); McMMOPlayer mcMMOPlayer = UserManager.getPlayer(player);
if (mcMMOPlayer == null) {
return;
}
mcMMOPlayer.actualizeTeleportATS();
} }
/** /**