Skip to content

Commit

Permalink
Fix bug in package split in case of git packages
Browse files Browse the repository at this point in the history
  • Loading branch information
Frank Schmid committed Jul 31, 2017
1 parent 932d9dc commit 266cdc3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/packExternalModules.js
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,8 @@ module.exports = {
};
const prodModules = getProdModules(getExternalModules(compileStats), packagePath);
_.forEach(prodModules, prodModule => {
const splitModule = _.split(prodModule, '@', 2);
modulePackage.dependencies[splitModule[0]] = splitModule[1];
const splitModule = _.split(prodModule, '@');
modulePackage.dependencies[_.first(splitModule)] = _.join(_.tail(splitModule), '');
});
this.serverless.utils.writeFileSync(modulePackageJson, JSON.stringify(modulePackage, null, 2));

Expand Down

0 comments on commit 266cdc3

Please sign in to comment.