mirror of
https://github.com/clap-rs/clap
synced 2025-01-18 23:53:54 +00:00
Merge pull request #211 from kbknapp/issue-210
fix(Unified Help Messages): fixes a crash from this setting and no opts
This commit is contained in:
commit
571a3516be
1 changed files with 1 additions and 1 deletions
|
@ -1636,7 +1636,7 @@ impl<'a, 'v, 'ab, 'u, 'h, 'ar> App<'a, 'v, 'ab, 'u, 'h, 'ar>{
|
|||
l
|
||||
);
|
||||
self.print_spaces(
|
||||
if !self.unified_help {
|
||||
if !self.unified_help || longest_opt == 0 {
|
||||
(longest_flag + 4)
|
||||
} else {
|
||||
(longest_opt + 4)
|
||||
|
|
Loading…
Reference in a new issue