From b811e322436d3dfb266ea76b2e2a987bbf204a2f Mon Sep 17 00:00:00 2001 From: Alec Thomas Date: Sun, 29 Dec 2024 18:02:02 +0900 Subject: [PATCH] fix: whoops, forgot to prefix "and" --- build.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/build.go b/build.go index 228c0e9..5d17f53 100644 --- a/build.go +++ b/build.go @@ -154,6 +154,12 @@ MAIN: } } + if len(tag.And) != 0 { + for i := range tag.And { + tag.And[i] = tag.XorPrefix + tag.And[i] + } + } + // Nested structs are either commands or args, unless they implement the Mapper interface. if field.value.Kind() == reflect.Struct && (tag.Cmd || tag.Arg) && k.registry.ForValue(fv) == nil { typ := CommandNode