mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-25 00:03:43 +00:00
Remove redundant is_terminal
check.
It's not necessary because `show_md_content_with_pager` is only ever called if `is_terminal` is true.
This commit is contained in:
parent
15528b2d6c
commit
91164957ec
@ -620,8 +620,7 @@ fn show_md_content_with_pager(content: &str, color: ColorConfig) {
|
||||
// to standard output
|
||||
if fallback_to_println {
|
||||
let fmt_success = match color {
|
||||
ColorConfig::Auto => io::stdout().is_terminal() && bufwtr.print(&mdbuf).is_ok(),
|
||||
ColorConfig::Always => bufwtr.print(&mdbuf).is_ok(),
|
||||
ColorConfig::Auto | ColorConfig::Always => bufwtr.print(&mdbuf).is_ok(),
|
||||
ColorConfig::Never => false,
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user