fix missing argument

This commit is contained in:
Franz Dietrich 2023-06-15 10:13:51 +02:00
parent e8cac82b4f
commit 53936258a9
1 changed files with 3 additions and 5 deletions

View File

@ -45,16 +45,14 @@ async fn main() {
.unwrap();
}
async fn register_form(extract::Path(name): extract::Path<String>) -> impl IntoResponse {
let template = HelloTemplate { name };
async fn register_form() -> impl IntoResponse {
let template = HelloTemplate {};
HtmlTemplate(template)
}
#[derive(Template)]
#[template(path = "hello.html")]
struct HelloTemplate {
name: String,
}
struct HelloTemplate {}
struct HtmlTemplate<T>(T);