change fn name

This commit is contained in:
Mylloon 2023-02-09 10:57:18 +01:00
parent 23774abc1b
commit 2a3045e5da
Signed by: Anri
GPG key ID: A82D63DFF8D1317F

View file

@ -3,14 +3,14 @@ use askama::Template;
#[get("/")]
pub async fn page() -> impl Responder {
HttpResponse::Ok().body(get_index())
HttpResponse::Ok().body(get_page())
}
#[derive(Template)]
#[template(path = "../templates/index.html")]
struct IndexTemplate {}
pub fn get_index() -> std::string::String {
pub fn get_page() -> std::string::String {
let index = IndexTemplate {};
index.render().unwrap()