We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0538c0c commit 7062177Copy full SHA for 7062177
cpp-linter/src/logger.rs
@@ -49,7 +49,10 @@ impl log::Log for SimpleLogger {
49
/// Returns a [`SetLoggerError`] if the `LOGGER` is already initialized.
50
pub fn init() -> Result<()> {
51
let logger: SimpleLogger = SimpleLogger;
52
- if env::var("CPP_LINTER_COLOR").is_ok_and(|v| ["on", "1", "true"].contains(&v.as_str())) {
+ if matches!(
53
+ env::var("CPP_LINTER_COLOR").as_deref(),
54
+ Ok("on" | "1" | "true")
55
+ ) {
56
set_override(true);
57
}
58
log::set_boxed_logger(Box::new(logger))
0 commit comments