diff --git a/actix-router/CHANGES.md b/actix-router/CHANGES.md index df93e5be..fefab81c 100644 --- a/actix-router/CHANGES.md +++ b/actix-router/CHANGES.md @@ -1,6 +1,9 @@ # Changes ## Unreleased - 2021-xx-xx +* `Router::recognize_mut_checked` take `&self` and return `Option<(&T, ResourceId)>` [#247] + +[#247]: https://github.com/actix/actix-net/pull/247 ## 0.2.6 - 2021-01-09 diff --git a/actix-service/CHANGES.md b/actix-service/CHANGES.md index 4bf41f0e..4a99d60a 100644 --- a/actix-service/CHANGES.md +++ b/actix-service/CHANGES.md @@ -1,6 +1,12 @@ # Changes ## Unreleased - 2021-xx-xx +* `Service::poll_ready` and `Service::call` take `&self`. [#247] +* `apply_fn` and `apply_fn_factory` would take `Fn(Req, &Service)` function type [#247] +* `apply_cfg` and `apply_cfg_factory` would take `Fn(Req, &Service)` function type [#247] +* `fn_service` module would take `Fn(Req)` function type. [#247] + +[#247]: https://github.com/actix/actix-net/pull/247 ## 2.0.0-beta.3 - 2021-01-09 diff --git a/actix-service/src/fn_service.rs b/actix-service/src/fn_service.rs index 53737fc2..230f437b 100644 --- a/actix-service/src/fn_service.rs +++ b/actix-service/src/fn_service.rs @@ -103,7 +103,7 @@ where pub struct FnService where - F: Fn(Req) -> Fut, + F: FnMut(Req) -> Fut, Fut: Future>, { f: F, @@ -112,7 +112,7 @@ where impl FnService where - F: Fn(Req) -> Fut, + F: FnMut(Req) -> Fut, Fut: Future>, { pub(crate) fn new(f: F) -> Self { @@ -122,7 +122,7 @@ where impl Clone for FnService where - F: Fn(Req) -> Fut + Clone, + F: FnMut(Req) -> Fut + Clone, Fut: Future>, { fn clone(&self) -> Self { diff --git a/actix-service/src/pipeline.rs b/actix-service/src/pipeline.rs index 824b6ece..0ec43f0d 100644 --- a/actix-service/src/pipeline.rs +++ b/actix-service/src/pipeline.rs @@ -172,13 +172,13 @@ where factory: I, ) -> PipelineFactory< impl ServiceFactory< - Req, - Response = SF1::Response, - Error = SF::Error, - Config = SF::Config, - InitError = SF::InitError, - Service = impl Service + Clone, - > + Clone, + Req, + Response = SF1::Response, + Error = SF::Error, + Config = SF::Config, + InitError = SF::InitError, + Service = impl Service + Clone, + > + Clone, Req, > where @@ -209,13 +209,13 @@ where factory: I, ) -> PipelineFactory< impl ServiceFactory< - Req, - Response = SF1::Response, - Error = SF::Error, - Config = SF::Config, - InitError = SF::InitError, - Service = impl Service + Clone, - > + Clone, + Req, + Response = SF1::Response, + Error = SF::Error, + Config = SF::Config, + InitError = SF::InitError, + Service = impl Service + Clone, + > + Clone, Req, > where