diff --git a/enumer.go b/enumer.go index 6c3d6fd..505827d 100644 --- a/enumer.go +++ b/enumer.go @@ -79,7 +79,7 @@ func (g *Generator) buildBasicExtras(runs [][]Value, typeName string, runsThresh // Print the basic extra methods g.Printf(stringNameToValueMethod, typeName) g.Printf(stringValuesMethod, typeName) - if len(runs) < runsThreshold { + if len(runs) <= runsThreshold { g.Printf(stringBelongsMethodLoop, typeName) } else { // There is a map of values, the code is simpler then g.Printf(stringBelongsMethodSet, typeName)