diff --git a/server/src/main.rs b/server/src/main.rs index bcf68c8..8e5474a 100755 --- a/server/src/main.rs +++ b/server/src/main.rs @@ -41,7 +41,7 @@ async fn main() -> std::io::Result<()> { for _ in 0..10 { let s = hex_string(10); - info!("Adding captcha key: {}", &s); + info!("Adding access key: {}", &s); capt_db.capthca_db.lock().unwrap().insert(s); } @@ -68,6 +68,10 @@ async fn main() -> std::io::Result<()> { ) .service( scope("/api") + .wrap( + middleware::DefaultHeaders::new() + .add(CacheControl(vec![CacheDirective::NoCache])), + ) .service(get_posts) .service(new_post) .service(delete_post)