mirror of
https://github.com/fafhrd91/actix-web
synced 2025-08-19 12:25:37 +02:00
rename .middleware to .wrap
This commit is contained in:
@@ -550,7 +550,7 @@ mod tests {
|
||||
use crate::test::{call_success, init_service, TestRequest};
|
||||
use crate::{web, App, Error, HttpResponse};
|
||||
|
||||
fn md1<S, P, B>(
|
||||
fn md<S, P, B>(
|
||||
req: ServiceRequest<P>,
|
||||
srv: &mut S,
|
||||
) -> impl IntoFuture<Item = ServiceResponse<B>, Error = Error>
|
||||
@@ -573,7 +573,7 @@ mod tests {
|
||||
let mut srv = init_service(
|
||||
App::new().service(
|
||||
web::resource("/test")
|
||||
.wrap(md1)
|
||||
.wrap(md)
|
||||
.route(web::get().to(|| HttpResponse::Ok())),
|
||||
),
|
||||
);
|
||||
|
Reference in New Issue
Block a user