mirror of
https://github.com/GTNewHorizons/TinkersConstruct.git
synced 2026-11-20 12:19:48 +00:00
Add missing null check for Knapsack loading #1542
This commit is contained in:
1 parent
2501749509
commit
5cf22cbc10
1 file changed
+1
-1
@@ -145,7 +145,7 @@ public class KnapsackInventory implements IInventory
|
||||
public void readFromNBT (NBTTagCompound tagCompound)
|
||||
{
|
||||
// player doesn't have a knapsack saved, tcon probably wasn't present before. don't error out.
|
||||
if(!tagCompound.hasKey("Knapsack"))
|
||||
if(tagCompound == null || !tagCompound.hasKey("Knapsack"))
|
||||
return;
|
||||
|
||||
NBTTagList tagList = tagCompound.getTagList("Knapsack", 10);
|
||||
|
||||
Reference in new issue
Block a user