From 499db25067edf8f23085e668e63454837892075a Mon Sep 17 00:00:00 2001 From: Sam Lucidi Date: Fri, 6 Oct 2023 08:48:51 -0400 Subject: [PATCH] PrepareForArchetype should use criteria and tags Previously PrepareForArchetype was using only the membership criteria to autofill assessments, but the enhancement specifies that it should use the archetype tags as well as the criteria tags. Fixes https://issues.redhat.com/browse/MTA-1396 Signed-off-by: Sam Lucidi --- assessment/pkg.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/assessment/pkg.go b/assessment/pkg.go index c1c70238d..6476314bd 100644 --- a/assessment/pkg.go +++ b/assessment/pkg.go @@ -103,6 +103,9 @@ func PrepareForArchetype(tagResolver *TagResolver, archetype *model.Archetype, a for _, t := range archetype.CriteriaTags { tagSet.Add(t.ID) } + for _, t := range archetype.Tags { + tagSet.Add(t.ID) + } assessment.Sections, _ = json.Marshal(prepareSections(tagResolver, tagSet, sections))