From e6998ff1feb3c5efac1458daa5006350c7e0eccd Mon Sep 17 00:00:00 2001 From: "Jose R. Gonzalez" Date: Wed, 10 Jan 2024 08:28:16 -0600 Subject: [PATCH] Catch whitespace csv.spec.provider.name values (#272) Signed-off-by: Jose R. Gonzalez --- pkg/validation/internal/operatorhub.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/validation/internal/operatorhub.go b/pkg/validation/internal/operatorhub.go index ea9bc03b5..2f5926cb9 100644 --- a/pkg/validation/internal/operatorhub.go +++ b/pkg/validation/internal/operatorhub.go @@ -296,7 +296,7 @@ func checkSpecMaintainers(checks CSVChecks) CSVChecks { // checkSpecProviderName will validate the values informed via csv.Spec.Provider.Name func checkSpecProviderName(checks CSVChecks) CSVChecks { - if checks.csv.Spec.Provider.Name == "" { + if strings.TrimSpace(checks.csv.Spec.Provider.Name) == "" { checks.errs = append(checks.errs, fmt.Errorf("csv.Spec.Provider.Name not specified")) } return checks