diff --git a/expr.go b/expr.go index c87a54e..9ccf400 100644 --- a/expr.go +++ b/expr.go @@ -295,7 +295,7 @@ func (a *aggregator) AggregateMatch(ctx context.Context, data map[string]any) ([ for groupID, matchingCount := range counts { requiredSize := int(groupID.Size()) // The total req size from the group ID - if matchingCount > requiredSize { + if matchingCount >= requiredSize { // The matching count met the group size; all results are safe. result = append(result, found[groupID]...) continue diff --git a/expr_test.go b/expr_test.go index 1e16e73..54dc8be 100644 --- a/expr_test.go +++ b/expr_test.go @@ -172,7 +172,7 @@ func TestEvaluate_Strings(t *testing.T) { require.NoError(t, err) require.EqualValues(t, 0, len(evals)) - require.EqualValues(t, 1, matched) // We still ran one expression + require.EqualValues(t, 0, matched) }) }