simplify entrypoint
This commit is contained in:
parent
b924819211
commit
17bec04f2c
1 changed files with 3 additions and 4 deletions
|
@ -30,11 +30,10 @@ async fn main() {
|
|||
.nest_service("/assets", assets_svc)
|
||||
.route("/signup", get(get_signup).post(post_signup))
|
||||
.route("/signup_success/:receipt", get(signup_success))
|
||||
.layer(session_layer);
|
||||
.layer(session_layer)
|
||||
.into_make_service();
|
||||
|
||||
let addr = SocketAddr::from(([127, 0, 0, 1], 3000));
|
||||
let listener = tokio::net::TcpListener::bind(&addr).await.unwrap();
|
||||
axum::serve(listener, app.into_make_service())
|
||||
.await
|
||||
.unwrap();
|
||||
axum::serve(listener, app).await.unwrap();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue