diff options
| author | Fuwn <[email protected]> | 2023-04-06 05:38:15 +0000 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2023-04-06 05:38:15 +0000 |
| commit | 2f7e1b76319ead455048627737972c015d8d3908 (patch) | |
| tree | 97451994c3e1f1de6abaf8301b406a8fbe6c3e22 | |
| parent | style(router): add associated types (diff) | |
| download | windmark-2f7e1b76319ead455048627737972c015d8d3908.tar.xz windmark-2f7e1b76319ead455048627737972c015d8d3908.zip | |
refactor(router): no need for pin
| -rw-r--r-- | src/router.rs | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/router.rs b/src/router.rs index 940bda0..f0ba97e 100644 --- a/src/router.rs +++ b/src/router.rs @@ -165,9 +165,7 @@ impl Router { .insert( route.into(), Arc::new(AsyncMutex::new(Box::new( - move |context: RouteContext<'_>| { - Box::pin(handler(context).into_future()) - }, + move |context: RouteContext<'_>| handler(context).into_future(), ))), ) .unwrap(); |