perf(config): añadido header para la búsquedo por IA en los permitidos por CORS

parent 2c026c2b
......@@ -21,7 +21,7 @@ public class CorsConfig {
registry.addMapping("/**")
.allowedOrigins("http://localhost:5173")
.allowedMethods("*")
.allowedHeaders("*");
.allowedHeaders("X-Session-ID", "Content-Type", "Authorization");
}
};
}
......@@ -31,7 +31,7 @@ public class CorsConfig {
CorsConfiguration config = new CorsConfiguration();
config.setAllowedOrigins(List.of("http://localhost:5173"));
config.setAllowedMethods(List.of("GET", "POST", "PUT", "DELETE", "OPTIONS", "PATCH"));
config.setAllowedHeaders(List.of("Authorization", "Content-Type"));
config.setAllowedHeaders(List.of("Authorization", "Content-Type", "X-Session-ID"));
UrlBasedCorsConfigurationSource source = new UrlBasedCorsConfigurationSource();
source.registerCorsConfiguration("/**", config);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment