diff --git a/server/src/api/mod.rs b/server/src/api/mod.rs index 174c474..0102034 100644 --- a/server/src/api/mod.rs +++ b/server/src/api/mod.rs @@ -6,7 +6,7 @@ mod internal; pub mod jsonapi; mod tempo; -use axum::Router; +use axum::{Router, http::header::{ACCEPT, AUTHORIZATION}}; use base::database::get_database; pub use error::Error; use eyre::Result; @@ -23,7 +23,7 @@ pub fn router() -> Result { let cors = CorsLayer::new() .allow_methods(Any) .allow_origin(Any) - .allow_headers(Any); + .allow_headers([AUTHORIZATION, ACCEPT]); let tracing = TraceLayer::new_for_http(); let conn = get_database()?.clone(); Ok(Router::new()