Drakulix / simplelog.rs

Simple Logging Facility for Rust
https://docs.rs/simplelog/
Apache License 2.0
414 stars 71 forks source link

ConfigBuilder::add_filter_allow example documentation #120

Closed chris-stones closed 1 year ago

chris-stones commented 1 year ago

is this missing the scope? ::

 /// For example, `add_filter_allow(format!("{}{}","tokio", "uds"))` would allow only logging from the `tokio` crates `uds` module.

should be the following?

 /// For example, `add_filter_allow(format!("{}::{}","tokio", "uds"))` would allow only logging from the `tokio` crates `uds` module.
chris-stones commented 1 year ago

Skimming the code, the documentation may be misleading here?

Since commit 7648343bd71dd2a631fb063a76af63a07d6cf754, this filter now operates on target, rather than module path.

Drakulix commented 1 year ago

Good catch, yes the documentation seems to be outdated here, I missed that on the PR that introduced this change. Are you perhaps available to do a fixup PR?

chris-stones commented 1 year ago

yep, ill fling one your way later, when I'm off-the-clock.