diff --git a/actix-utils/src/stream.rs b/actix-utils/src/stream.rs index 271aae06..7be9ccb9 100644 --- a/actix-utils/src/stream.rs +++ b/actix-utils/src/stream.rs @@ -43,15 +43,9 @@ where T::Service: 'static, >>::Future: 'static, { - // pub fn new>>(factory: F) -> Self { - // Self { - // factory: Rc::new(factory.into_new_service()), - // _t: PhantomData, - // } - // } - pub fn new(factory: T) -> Self { + pub fn new>>(factory: F) -> Self { Self { - factory: Rc::new(factory), + factory: Rc::new(factory.into_new_service()), _t: PhantomData, } }