diff --git a/src/lib.rs b/src/lib.rs index 6989405..ccb004b 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -26,8 +26,6 @@ SOFTWARE. //! //! This crate provides access to a set of strongly typed apis to interact with consul (https://www.consul.io/) #![deny(missing_docs)] - -use http::StatusCode; use http_body_util::BodyExt; #[cfg(feature = "metrics")] @@ -49,6 +47,9 @@ use serde::{Deserialize, Serialize}; use slog_scope::{error, info}; use tokio::time::timeout; +#[cfg(feature = "metrics")] +use http::StatusCode; + #[cfg(feature = "trace")] use opentelemetry::global; #[cfg(feature = "trace")]