Skip to content

Commit

Permalink
Merge pull request #616 from Electrical-Age/bugfix/lamp-waila-crash
Browse files Browse the repository at this point in the history
Fixed bug crashing server when autoplacing bulp into lamp
  • Loading branch information
cm0x4D committed Jan 24, 2017
2 parents 1938171 + 2ea1d8b commit 3780f28
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ public Map<String, String> getWaila() {
}
info.put(I18N.tr("Voltage"), Utils.plotVolt("", positiveLoad.getU()));
ItemStack lampStack = acceptingInventory.getInventory().getStackInSlot(0);
if (lampStack != null) {
if (lampStack != null && lampDescriptor != null) {
info.put(I18N.tr("Life"), Utils.plotValue(lampDescriptor.getLifeInTag(lampStack)));
}

Expand Down

1 comment on commit 3780f28

@AMIDIBOSS
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Such little change, but saves us from crashes 😆

Please sign in to comment.