diff --git a/pkg/chart/dependency.go b/pkg/chart/dependency.go index d9d4ee981..4ef5eeb32 100644 --- a/pkg/chart/dependency.go +++ b/pkg/chart/dependency.go @@ -54,7 +54,7 @@ type Dependency struct { // loaded. func (d *Dependency) Validate() error { if d == nil { - return ValidationError("dependency cannot be an empty list") + return ValidationError("dependencies must not contain empty or null nodes") } d.Name = sanitizeString(d.Name) d.Version = sanitizeString(d.Version) diff --git a/pkg/chart/metadata.go b/pkg/chart/metadata.go index 7d16ecd1b..ae572abb7 100644 --- a/pkg/chart/metadata.go +++ b/pkg/chart/metadata.go @@ -35,7 +35,7 @@ type Maintainer struct { // Validate checks valid data and sanitizes string characters. func (m *Maintainer) Validate() error { if m == nil { - return ValidationError("maintainer cannot be an empty list") + return ValidationError("maintainers must not contain empty or null nodes") } m.Name = sanitizeString(m.Name) m.Email = sanitizeString(m.Email) diff --git a/pkg/chart/metadata_test.go b/pkg/chart/metadata_test.go index 98354d13f..691e6bf46 100644 --- a/pkg/chart/metadata_test.go +++ b/pkg/chart/metadata_test.go @@ -82,7 +82,7 @@ func TestValidate(t *testing.T) { nil, }, }, - ValidationError("dependency cannot be an empty list"), + ValidationError("dependencies must not contain empty or null nodes"), }, { &Metadata{ @@ -94,7 +94,7 @@ func TestValidate(t *testing.T) { nil, }, }, - ValidationError("maintainer cannot be an empty list"), + ValidationError("maintainers must not contain empty or null nodes"), }, { &Metadata{APIVersion: "v2", Name: "test", Version: "1.2.3.4"},