[commands] Fix flag detection code in get_flags
This commit is contained in:
parent
e09f64b7c9
commit
8e9860077d
@ -184,7 +184,7 @@ def get_flags(namespace: Dict[str, Any], globals: Dict[str, Any], locals: Dict[s
|
||||
|
||||
annotation = flag.annotation = resolve_annotation(flag.annotation, globals, locals, cache)
|
||||
|
||||
if flag.default is MISSING and issubclass(annotation, FlagConverter) and annotation._can_be_constructible():
|
||||
if flag.default is MISSING and hasattr(annotation, '__commands_is_flag__') and annotation._can_be_constructible():
|
||||
flag.default = annotation._construct_default
|
||||
|
||||
if flag.aliases is MISSING:
|
||||
|
Loading…
x
Reference in New Issue
Block a user