1
0
mirror of https://github.com/fafhrd91/actix-web synced 2025-08-29 00:07:48 +02:00

rename .to_async() to .to()

This commit is contained in:
Nikolay Kim
2019-11-21 21:34:04 +06:00
parent 0b9e3d381b
commit 8683ba8bb0
25 changed files with 232 additions and 396 deletions

View File

@@ -475,9 +475,10 @@ pub(crate) mod tests {
let mut srv = init_service(
App::new()
.service(
web::resource("/none").to(|| -> Option<&'static str> { None }),
web::resource("/none")
.to(|| async { Option::<&'static str>::None }),
)
.service(web::resource("/some").to(|| Some("some"))),
.service(web::resource("/some").to(|| async { Some("some") })),
)
.await;