mirror of
https://github.com/tokio-rs/axum.git
synced 2026-08-27 00:00:24 +02:00
Work around for http2 hang with Or (#199)
This is a nasty hack that works around https://github.com/hyperium/hyper/issues/2621. Fixes https://github.com/tokio-rs/axum/issues/191
This commit is contained in:
@@ -16,7 +16,7 @@ async fn main() {
|
||||
tracing_subscriber::fmt::init();
|
||||
|
||||
// build our application with a route
|
||||
let app = route("/", get(handler));
|
||||
let app = route("/foo", get(handler)).or(route("/bar", get(handler)));
|
||||
|
||||
// run it
|
||||
let addr = SocketAddr::from(([127, 0, 0, 1], 3000));
|
||||
|
||||
Reference in New Issue
Block a user