mirror of
https://github.com/songoda/FabledSkyBlock.git
synced 2024-09-03 18:40:35 +02:00
Fix entity NPE because Spigot is great
This commit is contained in:
parent
f13a54e901
commit
1c0af0765e
|
@ -291,6 +291,9 @@ public class Entity implements Listener {
|
|||
return;
|
||||
|
||||
org.bukkit.entity.Entity target = event.getTarget();
|
||||
// Somehow the target can be null, thanks Spigot.
|
||||
if (target == null)
|
||||
return;
|
||||
|
||||
IslandManager islandManager = skyblock.getIslandManager();
|
||||
Island entityIsland = islandManager.getIslandAtLocation(entity.getLocation());
|
||||
|
|
Loading…
Reference in New Issue
Block a user