Skip to content

Commit

Permalink
refactor(CLI): Move var declaration
Browse files Browse the repository at this point in the history
  • Loading branch information
medikoo committed Jan 27, 2022
1 parent a92ab91 commit e597474
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions scripts/serverless.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,6 @@ let hasTelemetryBeenReported = false;
// to properly handle e.g. `SIGINT` interrupt
const keepAliveTimer = setTimeout(() => {}, 60 * 60 * 1000);

// Names of the commands which are configured independently in root `commands` folder
// and not in Serverless class internals
const notIntegratedCommands = new Set(['doctor', 'plugin install', 'plugin uninstall']);

process.once('uncaughtException', (error) => {
clearTimeout(keepAliveTimer);
progress.clear();
Expand Down Expand Up @@ -476,6 +472,9 @@ const processSpanPromise = (async () => {

const configurationFilename = configuration && configurationPath.slice(serviceDir.length + 1);

// Names of the commands which are configured independently in root `commands` folder
// and not in Serverless class internals
const notIntegratedCommands = new Set(['doctor', 'plugin install', 'plugin uninstall']);
const isStandaloneCommand = notIntegratedCommands.has(command);

if (!isHelpRequest && (isInteractiveSetup || isStandaloneCommand)) {
Expand Down

0 comments on commit e597474

Please sign in to comment.