This commit is contained in:
Igor Katson 2025-01-30 11:24:43 +00:00
parent 62d5288398
commit 3e6c2eae79
No known key found for this signature in database
GPG key ID: B4EC22B66D61A3F5
5 changed files with 36 additions and 24 deletions

View file

@ -26,7 +26,7 @@ async fn h_api_root(parts: Parts) -> impl IntoResponse {
.headers
.get("Accept")
.and_then(|h| h.to_str().ok())
.map_or(false, |h| h.contains("text/html"))
.is_some_and(|h| h.contains("text/html"))
{
return Redirect::temporary("./web/").into_response();
}