From 23d1aa9f471395e36951d9062a9c20b8c4d98dd5 Mon Sep 17 00:00:00 2001 From: Mark Lee Date: Mon, 23 Jan 2017 23:48:31 -0800 Subject: [PATCH] style(generic): remove unnecessary eslint pragmas --- src/api/publish.js | 2 +- src/installers/darwin/dmg.js | 1 - src/publishers/github.js | 2 +- src/util/move-app.js | 1 - 4 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/api/publish.js b/src/api/publish.js index b0e5ec3519..cf15704fdc 100644 --- a/src/api/publish.js +++ b/src/api/publish.js @@ -60,7 +60,7 @@ export default async (providedOptions = {}) => { `electron-forge-publisher-${target}`, ]); if (!publisher) { - throw `Could not find a publish target with the name: ${target}`; // eslint-disable-line + throw `Could not find a publish target with the name: ${target}`; } }); diff --git a/src/installers/darwin/dmg.js b/src/installers/darwin/dmg.js index 72c1e29d95..8517574849 100644 --- a/src/installers/darwin/dmg.js +++ b/src/installers/darwin/dmg.js @@ -17,7 +17,6 @@ export default async (filePath, installSpinner) => { const volumePath = path.resolve('/Volumes', targetMount.mountPath); const appName = (await fs.readdir(volumePath)).find(file => file.endsWith('.app')); if (!appName) { - // eslint-disable-next-line no-throw-literal throw 'Failed to find .app file in DMG'; } const appPath = path.resolve(volumePath, appName); diff --git a/src/publishers/github.js b/src/publishers/github.js index 4b518e6e38..2388918e3c 100644 --- a/src/publishers/github.js +++ b/src/publishers/github.js @@ -21,7 +21,7 @@ export default async (artifacts, packageJSON, forgeConfig, authToken, tag) => { per_page: 100, })).find(testRelease => testRelease.tag_name === (tag || `v${packageJSON.version}`)); if (!release) { - throw { code: 404 }; // eslint-disable-line + throw { code: 404 }; } } catch (err) { if (err.code === 404) { diff --git a/src/util/move-app.js b/src/util/move-app.js index e602576bc3..d7dbb9b0f5 100644 --- a/src/util/move-app.js +++ b/src/util/move-app.js @@ -21,7 +21,6 @@ export default async (appPath, targetApplicationPath, spinner, copyInstead = fal message: `The application "${path.basename(targetApplicationPath)}" appears to already exist in /Applications. Do you want to replace it?`, }); if (!confirm) { - // eslint-disable-next-line no-throw-literal throw 'Installation stopped by user'; } else { spinner.start();