From phantom-node to node-phantom - better error handling