Skip to content

Commit

Permalink
Null check for completeness sake
Browse files Browse the repository at this point in the history
  • Loading branch information
fullwall committed Jan 1, 2022
1 parent fe15df7 commit fdba356
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -551,7 +551,7 @@ private PlayerNPC(EntityHumanNPC entity) {

@Override
public boolean canSee(org.bukkit.entity.Entity entity) {
if (entity.getType() == EntityType.ITEM_FRAME) {
if (entity != null && entity.getType() == EntityType.ITEM_FRAME) {
return false; // optimise for large maps in item frames
}
return super.canSee(entity);
Expand Down

0 comments on commit fdba356

Please sign in to comment.