From b4c176dd49131f2da968f5f52f2d8aedaac89779 Mon Sep 17 00:00:00 2001 From: hawardShin Date: Mon, 25 Nov 2024 10:20:01 +0900 Subject: [PATCH] Fix: PUT Cors Error --- .../java/capstone/relation/api/auth/config/SecurityConfig.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/capstone/relation/api/auth/config/SecurityConfig.java b/src/main/java/capstone/relation/api/auth/config/SecurityConfig.java index 74f2ce3..467bbbc 100644 --- a/src/main/java/capstone/relation/api/auth/config/SecurityConfig.java +++ b/src/main/java/capstone/relation/api/auth/config/SecurityConfig.java @@ -43,7 +43,7 @@ public SecurityFilterChain filterChain(HttpSecurity http) throws Exception { public CorsConfigurationSource corsConfigurationSource() { CorsConfiguration configuration = new CorsConfiguration(); configuration.setAllowedOriginPatterns(List.of("*")); - configuration.setAllowedMethods(Arrays.asList("GET", "POST", "PATCH", "DELETE")); + configuration.setAllowedMethods(Arrays.asList("GET", "POST", "PUT", "PATCH", "DELETE")); configuration.setAllowedHeaders(List.of("*")); configuration.setAllowCredentials(true); configuration.setMaxAge(3600L); // 필요에 따라 조정