Skip to content
Permalink
Browse files

fix(importer): check updateScripts value at script install vs deps re…

…moval
  • Loading branch information
anulman authored and MarshallOfSound committed Feb 6, 2017
1 parent 9dcf2ec commit 4942cb601f62296690594167bc18690a3a6c18ec
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/api/import.js
@@ -101,7 +101,7 @@ export default async (providedOptions = {}) => {
} else if (buildToolPackages[key]) {
const explanation = buildToolPackages[key];
// eslint-disable-next-line max-len
const shouldRemoveDependency = await confirmIfInteractive(interactive, `Do you want us to remove the "${key}" dependency in package.json? Electron Forge ${explanation}.`, updateScripts);
const shouldRemoveDependency = await confirmIfInteractive(interactive, `Do you want us to remove the "${key}" dependency in package.json? Electron Forge ${explanation}.`);

if (shouldRemoveDependency) {
delete packageJSON.dependencies[key];
@@ -116,7 +116,7 @@ export default async (providedOptions = {}) => {
const updatePackageScript = async (scriptName, newValue) => {
if (packageJSON.scripts[scriptName] !== newValue) {
// eslint-disable-next-line max-len
const shouldUpdate = await confirmIfInteractive(interactive, `Do you want us to update the "${scriptName}" script to instead call the electron-forge task "${newValue}"`);
const shouldUpdate = await confirmIfInteractive(interactive, `Do you want us to update the "${scriptName}" script to instead call the electron-forge task "${newValue}"`, updateScripts);
if (shouldUpdate) {
packageJSON.scripts[scriptName] = newValue;
}

0 comments on commit 4942cb6

Please sign in to comment.
You can’t perform that action at this time.