Skip to content

Commit 824b759

Browse files
author
Frank Schmid
committed
Fixed issue with default output options.
1 parent 89ab12e commit 824b759

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

lib/validate.js

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -102,16 +102,10 @@ module.exports = {
102102
// Default output
103103
if (!this.webpackConfig.output) {
104104
const outputPath = path.join(this.serverless.config.servicePath, '.webpack');
105-
const outputFilename = path.basename(
106-
_.isArray(this.webpackConfig.entry)
107-
&& this.webpackConfig.entry[this.webpackConfig.entry.length - 1]
108-
|| this.webpackConfig.entry
109-
|| 'handler.js'
110-
);
111105
this.webpackConfig.output = {
112106
libraryTarget: 'commonjs',
113107
path: outputPath,
114-
filename: outputFilename,
108+
filename: '[name].js',
115109
};
116110
}
117111

0 commit comments

Comments
 (0)