mirror of
https://github.com/Thorfusion/Mekanism-Community-Edition.git
synced 2026-11-27 15:23:16 +00:00
Fix for a gas-generator with empty tank throwing exception during onChunkLoad (bug #2148)
This commit is contained in:
1 parent
079ca960ee
commit
8570748ad9
1 file changed
+2
-1
@@ -266,7 +266,8 @@ public class TileEntityGasGenerator extends TileEntityGenerator implements IGasH
|
||||
|
||||
fuelTank.read(nbtTags.getCompoundTag("fuelTank"));
|
||||
|
||||
FuelGas fuel = FuelHandler.getFuel(fuelTank.getGas().getGas());
|
||||
boolean isTankEmpty = (fuelTank.getGas() == null);
|
||||
FuelGas fuel = (isTankEmpty) ? null : FuelHandler.getFuel(fuelTank.getGas().getGas());
|
||||
|
||||
if(fuel != null)
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user