pub trait LogError<T> { // Required method fn log_err(self, context: &str) -> Option<T>; }
Extension trait for logging errors before discarding them.
Log the error at debug level and convert to Option.