refactor(help): Clarify usage condition

This commit is contained in:
Ed Page 2023-11-09 12:00:52 -06:00
parent 676e934a61
commit 7472aba6ce

View file

@ -132,8 +132,8 @@ impl<'cmd> Usage<'cmd> {
self.write_args(styled, &[], !incl_reqs); self.write_args(styled, &[], !incl_reqs);
// incl_reqs is only false when this function is called recursively // incl_reqs is only false when this function is called recursively
if self.cmd.has_visible_subcommands() && incl_reqs if (self.cmd.has_visible_subcommands() || self.cmd.is_allow_external_subcommands_set())
|| self.cmd.is_allow_external_subcommands_set() && incl_reqs
{ {
let value_name = self let value_name = self
.cmd .cmd