Skip to content

Commit

Permalink
Use http status code 204 No Content for the empty response to favicon…
Browse files Browse the repository at this point in the history
….ico from status server.
  • Loading branch information
ctsrc committed Aug 25, 2024
1 parent 9c3c090 commit c9a1692
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -454,6 +454,7 @@ async fn request_handler_status(
.body(Either::Left(INTERNAL_INDEX_PAGE.into())),
(&Method::GET, "favicon.ico") => response_builder
.header(header::CONTENT_TYPE, HeaderValue::from_static(IMAGE_X_ICON))
.status(StatusCode::NO_CONTENT)
.body(Either::Left("".into())),
(&Method::GET, "style/main.css") => response_builder
.header(header::CONTENT_TYPE, HeaderValue::from_static(TEXT_CSS))
Expand Down

0 comments on commit c9a1692

Please sign in to comment.