Skip to content

Commit 79ea8df

Browse files
committed
Fix unstable tests
1 parent 583fa50 commit 79ea8df

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

tests/nested.rs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,10 +51,11 @@ async fn nested_middleware() -> tide::Result<()> {
5151
async fn nested_with_different_state() -> tide::Result<()> {
5252
let mut outer = tide::new();
5353
let mut inner = tide::with_state(42);
54-
inner.at("/").get(|req: tide::Request<i32>| async move {
55-
let num = state;
56-
Ok(format!("the number is {}", num))
57-
});
54+
inner
55+
.at("/")
56+
.get(
57+
|_req: tide::Request, state: i32| async move { Ok(format!("the number is {}", state)) },
58+
);
5859
outer.at("/").get(|_, _| async { Ok("Hello, world!") });
5960
outer.at("/foo").nest(inner);
6061

0 commit comments

Comments
 (0)