another null check needed

the crafting helper is not used anywhere other than the 3 places that
have null checks. (this was the third location)
This commit is contained in:
Andrew Hill 2013-02-21 01:50:51 +10:00
parent a48e184ddb
commit 131f2459ed

View file

@ -148,7 +148,9 @@ public class TileAutoWorkbench extends TileEntity implements ISpecialInventory {
if(this.currentRecipe == null || !this.currentRecipe.matches(craftMatrix, worldObj))
currentRecipe = CraftingHelper.findMatchingRecipe(craftMatrix, worldObj);
return currentRecipe.getCraftingResult(craftMatrix);
if(currentRecipe!=null)
return currentRecipe.getCraftingResult(craftMatrix);
return null;
}
public ItemStack extractItem(boolean doRemove, boolean removeRecipe) {