shama/gulp-webpack — pull request #13 by btipling (2014-07-27 19:10:17+00:00)
Title: Don't sent entry to undefined

When there is nothing `entry` `entry[0]` sets `entry` to be undefined which breaks `gulp-webpack`:

```
│
/Users/bjorn/projects/polydamas/node_modules/gulp-webpack/index.js:47 │> polydamas@0.0.1 demo /Users/bjorn/projects/polydamas
entry.push(file.path); │> ./rundemo.sh
^ │
TypeError: Cannot call method 'push' of undefined
```

This happened with the following config:

```
gulp.task('webpack', function () {
return gulp.src('demo/jsx/*.js')
.pipe(webpack( require('./webpack.config.js') ))
.pipe(gulp.dest('dist/'));
});
```

```
module.exports = {
entry: "./demo/jsx/label.js",
output: {
filename: "./demo/js/label.js"
},
module: {
loaders: [
{ test: /\.css$/, loader: "style!css" }
]
}
};
```