diff --git a/src/main.rs b/src/main.rs index c91cf22..168b92f 100644 --- a/src/main.rs +++ b/src/main.rs @@ -33,7 +33,7 @@ use tower_governor::{ }; use tower_http::{ compression::CompressionLayer, - cors::{Any, CorsLayer}, + cors::{AllowHeaders, Any, CorsLayer}, }; use tracing::log; use tracing_subscriber::{EnvFilter, fmt, prelude::*}; @@ -352,7 +352,7 @@ async fn main() -> Result<(), Box> { let cors = CorsLayer::new() .allow_origin(Any) .allow_methods([Method::GET, Method::OPTIONS, Method::POST]) - .allow_headers(Any); + .allow_headers(AllowHeaders::mirror_request()); let mut app = Router::new() .route("/", get(root_handler))