mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-13 00:37:52 +00:00
Fix potential NPE in Custom item entity span code caused by item id misconfigurations.
This commit is contained in:
1 parent
61c21218e2
commit
de24eea885
1 file changed
+1
-1
@@ -13,7 +13,7 @@ public class ForgeInternalHandler
|
||||
if (entity instanceof EntityItem)
|
||||
{
|
||||
ItemStack item = ((EntityItem)entity).item;
|
||||
if (item.getItem().hasCustomEntity(item))
|
||||
if (item != null && item.getItem().hasCustomEntity(item))
|
||||
{
|
||||
Entity newEntity = item.getItem().createEntity(event.world, entity, item);
|
||||
if (newEntity != null)
|
||||
|
||||
Reference in new issue
Block a user