diff options
author | Tyler Murphy <tylermurphy534@gmail.com> | 2023-02-13 22:41:09 -0500 |
---|---|---|
committer | Tyler Murphy <tylermurphy534@gmail.com> | 2023-02-13 22:41:09 -0500 |
commit | b6fbeb512405542af0aed11ca123b7ac8ee0b04d (patch) | |
tree | 8cd9a708af765c266c6810e78c68ae9003008030 /src/public/mod.rs | |
parent | fix login redirect (diff) | |
download | xssbook-b6fbeb512405542af0aed11ca123b7ac8ee0b04d.tar.gz xssbook-b6fbeb512405542af0aed11ca123b7ac8ee0b04d.tar.bz2 xssbook-b6fbeb512405542af0aed11ca123b7ac8ee0b04d.zip |
fix seo
Diffstat (limited to 'src/public/mod.rs')
-rw-r--r-- | src/public/mod.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/public/mod.rs b/src/public/mod.rs index 82c994d..76796ea 100644 --- a/src/public/mod.rs +++ b/src/public/mod.rs @@ -35,6 +35,7 @@ pub fn router() -> Router { Router::new() .nest("/", pages::router()) .route("/favicon.ico", get(file::favicon)) + .route("/robots.txt", get(file::robots)) .route("/js/*path", get(file::js)) .route("/css/*path", get(file::css)) .route("/fonts/*path", get(file::fonts)) @@ -71,7 +72,7 @@ pub async fn serve(path: &str) -> Response { res.headers_mut().insert( HeaderName::from_static("cache-control"), - HeaderValue::from_static("public max-age=300"), + HeaderValue::from_static("max-age=300"), ); res.into_response() |