From fbe847eaadcc87c5fcc48622c730179e2e9e247a Mon Sep 17 00:00:00 2001 From: LukeMathWalker Date: Wed, 27 Oct 2021 09:35:30 +0100 Subject: [PATCH] Fix clippy lint --- src/root_span_macro.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/root_span_macro.rs b/src/root_span_macro.rs index 78a239a44..d5f4b0b74 100644 --- a/src/root_span_macro.rs +++ b/src/root_span_macro.rs @@ -123,6 +123,10 @@ pub mod private { pub use tracing; #[doc(hidden)] + // We need to allow unused variables because the function + // body is empty if the user of the library chose not to activate + // any OTEL feature. + #[allow(unused_variables)] pub fn set_otel_parent(req: &ServiceRequest, span: &tracing::Span) { #[cfg(any( feature = "opentelemetry_0_13",