Skip to content

Commit

Permalink
removed useless lifetime
Browse files Browse the repository at this point in the history
  • Loading branch information
leon3s committed Jan 12, 2024
1 parent fd15120 commit 2bd1d58
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion examples/middleware/src/errorhandler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ where

ntex::forward_poll_ready!(service);

async fn call<'a>(&self, req: web::WebRequest<Err>, ctx: ServiceCtx<'a, Self>) -> Result<Self::Response, Self::Error> {
async fn call(&self, req: web::WebRequest<Err>, ctx: ServiceCtx<'_, Self>) -> Result<Self::Response, Self::Error> {
ctx.call(&self.service, req).await.map(|mut res| {
let status = res.status();
if status.is_client_error() || status.is_server_error() {
Expand Down
2 changes: 1 addition & 1 deletion examples/middleware/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ where

ntex::forward_poll_ready!(service);

async fn call<'a>(&self, req: web::WebRequest<Err>, ctx: ServiceCtx<'a, Self>) -> Result<Self::Response, Self::Error> {
async fn call(&self, req: web::WebRequest<Err>, ctx: ServiceCtx<'_, Self>) -> Result<Self::Response, Self::Error> {
println!("Hi from start. You requested: {}", req.path());
let res = ctx.call(&self.service, req).await?;
println!("Hi from response");
Expand Down

0 comments on commit 2bd1d58

Please sign in to comment.