From a593ea9286eccdae0d1a8b79cb3a70c79e7e0553 Mon Sep 17 00:00:00 2001 From: Ryan Cahill Date: Wed, 30 Nov 2022 10:41:15 -0500 Subject: [PATCH] fix(register): Fix warning when dependencies are already registered (#766) --- src/commands/register.ts | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/src/commands/register.ts b/src/commands/register.ts index b3a8a6dea..ab5992eea 100644 --- a/src/commands/register.ts +++ b/src/commands/register.ts @@ -442,22 +442,19 @@ export default class ComponentRegister extends BaseCommand { } } - if (component_warnings || tag_warnings) { - this.log(); - this.log(chalk.yellow(`Some required dependencies for this component have not yet been registered to your account. Please make sure to register the following before you try to deploy.`)); + if (component_warnings.length > 0 || tag_warnings.length > 0) { + this.log(chalk.yellow(`\nSome required dependencies for this component have not yet been registered to your account. Please make sure to register the following before you try to deploy.`)); } if (component_warnings.length > 0) { - this.log(); - this.log(chalk.yellow(`The following components do not exist.`)); + this.log(chalk.yellow(`\nThe following components do not exist.`)); for (const component_name of component_warnings) { this.log(chalk.yellow(` - ${component_name}`)); } } if (tag_warnings.length > 0) { - this.log(); - this.log(chalk.yellow(`The following components exist, but do not have the specified tag.`)); + this.log(chalk.yellow(`\nThe following components exist, but do not have the specified tag.`)); for (const component_name of tag_warnings) { this.log(chalk.yellow(` - ${component_name}`)); }