Skip to content

Commit

Permalink
Merge pull request #114 from ayan4m1/fix/cce
Browse files Browse the repository at this point in the history
Prevent ClassCastException
  • Loading branch information
modmuss50 authored Aug 11, 2018
2 parents 0454de5 + dcbba5e commit 54ea2ae
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package me.modmuss50.rebornstorage.tiles;

import com.raoulvdberge.refinedstorage.api.network.node.INetworkNode;
import com.raoulvdberge.refinedstorage.api.network.node.INetworkNodeManager;
import com.raoulvdberge.refinedstorage.api.network.node.INetworkNodeProxy;
import com.raoulvdberge.refinedstorage.apiimpl.API;
Expand Down Expand Up @@ -200,13 +201,13 @@ public CraftingNode getNode() {
return clientNode;
}
INetworkNodeManager manager = API.instance().getNetworkNodeManager(this.world);
CraftingNode node = (CraftingNode) manager.getNode(this.pos);
INetworkNode node = manager.getNode(this.pos);
if (node == null || !node.getId().equals(RebornStorage.MULTI_BLOCK_ID)) {
manager.setNode(this.pos, node = new CraftingNode(world, getPos()));
manager.markForSaving();
}

return node;
return (CraftingNode) node;
}

@Override
Expand Down

0 comments on commit 54ea2ae

Please sign in to comment.