Skip to content

Commit

Permalink
fix program.error calls so they use thrown error messages (#942)
Browse files Browse the repository at this point in the history
  • Loading branch information
adrianmroz-allegro authored Nov 18, 2022
1 parent 56b79e4 commit 7629159
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/server/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ program
const config = loadConfigFile(file, program);
buildSettings(config, { verbose });
} catch (e) {
program.error("Config verification error: ", e.message);
program.error(`Config verification error: ${e.message}`);
}
});

Expand All @@ -170,10 +170,8 @@ program
verbose,
version
).catch((e: Error) => {
program.error("There was an error generating a config: " + e.message);
program.error(`There was an error generating a config: ${e.message}`);
});
});

program.showHelpAfterError();

program.parse();

0 comments on commit 7629159

Please sign in to comment.