Add Status Codes to Error Pages

This commit is contained in:
spikecodes 2020-11-20 20:43:20 -08:00
parent 0f88936909
commit cef3266186
4 changed files with 4 additions and 4 deletions

View file

@ -28,7 +28,7 @@ async fn render(id: String, sort: String) -> Result<HttpResponse> {
}
.render()
.unwrap();
Ok(HttpResponse::Ok().content_type("text/html").body(s))
Ok(HttpResponse::Ok().status(actix_web::http::StatusCode::NOT_FOUND).content_type("text/html").body(s))
} else {
let s = PostTemplate {
comments: comments.unwrap(),