mirror of https://github.com/rwf2/Rocket.git
Drop Rocket inside the tokio async context when using launch
Moves error printing and the implicit drop inside the tokio runtime when using the `#[launch]` attribute.
This commit is contained in:
parent
9496b70e8c
commit
02680076eb
|
@ -113,7 +113,9 @@ impl EntryAttr for Launch {
|
|||
#[allow(dead_code)] #f
|
||||
|
||||
#vis #sig {
|
||||
#_error::Error::report(::rocket::async_main(#launch))
|
||||
::rocket::async_main(async move {
|
||||
#_error::Error::report(#launch.await)
|
||||
})
|
||||
}
|
||||
))
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue