From 6e0f0e1951b7a3bf7b8b2e1721ca8dae2939d57b Mon Sep 17 00:00:00 2001 From: Oksana Grishchenko Date: Wed, 14 Feb 2024 15:45:38 +0200 Subject: [PATCH] linter, address comments --- pkg/install/install.go | 4 ++-- pkg/upgrade/upgrade.go | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/install/install.go b/pkg/install/install.go index e8c29ef3..d434a302 100644 --- a/pkg/install/install.go +++ b/pkg/install/install.go @@ -183,7 +183,7 @@ func (o *Install) populateConfig() error { } } - if len(o.config.Namespaces) == 0 { + if len(o.config.NamespacesList()) == 0 { return errors.New("namespace list is empty. Specify the comma-separated list of namespaces using the --namespaces flag, at least one namespace is required") } @@ -358,7 +358,7 @@ func (o *Install) runEverestWizard() error { o.config.Namespaces += "," + ns } - if len(o.config.Namespaces) == 0 { + if len(o.config.NamespacesList()) == 0 { return errors.New("namespace list is empty. Specify at least one namespace") } diff --git a/pkg/upgrade/upgrade.go b/pkg/upgrade/upgrade.go index 072fc6cd..4210fa4b 100644 --- a/pkg/upgrade/upgrade.go +++ b/pkg/upgrade/upgrade.go @@ -85,7 +85,7 @@ func (u *Upgrade) Run(ctx context.Context) error { if err := u.runEverestWizard(ctx); err != nil { return err } - if len(u.config.Namespaces) == 0 { + if len(u.config.NamespacesList()) == 0 { return errors.New("namespace list is empty. Specify at least one namespace") } if err := u.upgradeOLM(ctx); err != nil {