From 768e81741cbd2bb16e18edb0782b64d270a86dfd Mon Sep 17 00:00:00 2001 From: Jason Volk Date: Sun, 3 Nov 2024 11:22:38 +0000 Subject: [PATCH] use FnMut for ready_try_for_each extension Signed-off-by: Jason Volk --- src/core/utils/stream/try_ready.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/core/utils/stream/try_ready.rs b/src/core/utils/stream/try_ready.rs index feb38067..3fbcbc45 100644 --- a/src/core/utils/stream/try_ready.rs +++ b/src/core/utils/stream/try_ready.rs @@ -24,7 +24,7 @@ where self, f: F, ) -> TryForEach>, impl FnMut(S::Ok) -> Ready>> where - F: Fn(S::Ok) -> Result<(), E>; + F: FnMut(S::Ok) -> Result<(), E>; } impl TryReadyExt for S @@ -42,10 +42,10 @@ where #[inline] fn ready_try_for_each( - self, f: F, + self, mut f: F, ) -> TryForEach>, impl FnMut(S::Ok) -> Ready>> where - F: Fn(S::Ok) -> Result<(), E>, + F: FnMut(S::Ok) -> Result<(), E>, { self.try_for_each(move |t| ready(f(t))) }