Skip to content

Commit

Permalink
Merge pull request #6 from jeffijoe/fix/log
Browse files Browse the repository at this point in the history
Fix logging again
  • Loading branch information
jeffijoe authored Jun 13, 2023
2 parents f9b7828 + 5569064 commit 99cbd13
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ async fn main_core(args: Cli) -> Result<(), Box<dyn std::error::Error>> {
env_logger::builder()
.format_target(false)
.filter_level(LevelFilter::Off)
.filter_module("deltio:*", map_log_level(args.log))
.filter_module("deltio", map_log_level(&args.log))
.parse_default_env()
.init();

Expand Down Expand Up @@ -92,7 +92,7 @@ async fn main_core(args: Cli) -> Result<(), Box<dyn std::error::Error>> {
}

/// Maps the log level argument to the `LevelFilter` enum.
fn map_log_level(level: LogLevelArg) -> LevelFilter {
fn map_log_level(level: &LogLevelArg) -> LevelFilter {
match level {
LogLevelArg::Off => LevelFilter::Off,
LogLevelArg::Error => LevelFilter::Error,
Expand Down

0 comments on commit 99cbd13

Please sign in to comment.