Added code to ensure that errors that occur via http-proxy don't take down the whole node process