better error handling in browserify bundling