set correct content type
This commit is contained in:
parent
19080cc0e7
commit
e56e43651c
1 changed files with 2 additions and 2 deletions
|
@ -30,7 +30,7 @@ async fn blog() -> impl Responder {
|
||||||
true,
|
true,
|
||||||
)
|
)
|
||||||
.unwrap_or_else(|e| panic!("Error, couldn't render blog template.\n{}", e));
|
.unwrap_or_else(|e| panic!("Error, couldn't render blog template.\n{}", e));
|
||||||
HttpResponse::Ok().body(result)
|
HttpResponse::Ok().content_type("text/html").body(result)
|
||||||
}
|
}
|
||||||
|
|
||||||
#[get("/blog/submit")]
|
#[get("/blog/submit")]
|
||||||
|
@ -63,7 +63,7 @@ async fn blog_permalink(web::Path(post_id): web::Path<std::string::String>) -> i
|
||||||
true,
|
true,
|
||||||
)
|
)
|
||||||
.unwrap_or_else(|e| panic!("Error, couldn't render blog template.\n{}", e));
|
.unwrap_or_else(|e| panic!("Error, couldn't render blog template.\n{}", e));
|
||||||
HttpResponse::Ok().body(result)
|
HttpResponse::Ok().content_type("text/html").body(result)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue