From 065d69dced52500436058110c6bc0528012c47ad Mon Sep 17 00:00:00 2001 From: tottoto Date: Fri, 10 May 2024 19:09:41 +0900 Subject: [PATCH] chore(client): move legacy client builder http2 timer config to http2 feature --- src/client/legacy/client.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/client/legacy/client.rs b/src/client/legacy/client.rs index 0518392b..93ed62a5 100644 --- a/src/client/legacy/client.rs +++ b/src/client/legacy/client.rs @@ -1458,11 +1458,12 @@ impl Builder { /// details. /// /// [`h2::client::Builder::timer`]: https://docs.rs/h2/client/struct.Builder.html#method.timer - pub fn timer(&mut self, timer: M) -> &mut Self + #[cfg(feature = "http2")] + #[cfg_attr(docsrs, doc(cfg(feature = "http2")))] + pub fn http2_timer(&mut self, timer: M) -> &mut Self where M: Timer + Send + Sync + 'static, { - #[cfg(feature = "http2")] self.h2_builder.timer(timer); self }