Null check

This commit is contained in:
Trent Hensler
2018-01-01 00:24:42 -08:00
parent c1ff332565
commit e8843bc054
2 changed files with 4 additions and 2 deletions
@@ -142,7 +142,9 @@ public class VaultManager {
// In this case, players will lose items.
if (deserialized.getContents().length > size) {
for (ItemStack stack : deserialized.getContents()) {
inventory.addItem(stack);
if (stack != null) {
inventory.addItem(stack);
}
}
} else {
inventory.setContents(deserialized.getContents());