Fixes crash with IC2

http://pastebin.com/qy6nW8v2