fix(help): Command::print_help should respect disable_colored_help

This commit is contained in:
Ed Page 2022-08-29 10:47:00 -05:00
parent a2f3ee2cfa
commit 4eeee9b110

View file

@ -717,7 +717,7 @@ impl Command {
/// [`io::stdout()`]: std::io::stdout()
pub fn print_help(&mut self) -> io::Result<()> {
self._build_self();
let color = self.get_color();
let color = self.color_help();
let mut styled = StyledStr::new();
let usage = Usage::new(self);
@ -744,7 +744,7 @@ impl Command {
/// [`--help` (long)]: Arg::long_help()
pub fn print_long_help(&mut self) -> io::Result<()> {
self._build_self();
let color = self.get_color();
let color = self.color_help();
let mut styled = StyledStr::new();
let usage = Usage::new(self);