From 68989fe5a6486cea90d5c79dff36e7a9620e8b75 Mon Sep 17 00:00:00 2001 From: EarlyXS Date: Wed, 20 Aug 2025 19:05:28 +0900 Subject: [PATCH] cors error fixed --- .../likelion13th/canfly/global/config/SecurityConfig.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/hackerthon/likelion13th/canfly/global/config/SecurityConfig.java b/src/main/java/hackerthon/likelion13th/canfly/global/config/SecurityConfig.java index 89c7161..ceb23bf 100644 --- a/src/main/java/hackerthon/likelion13th/canfly/global/config/SecurityConfig.java +++ b/src/main/java/hackerthon/likelion13th/canfly/global/config/SecurityConfig.java @@ -80,7 +80,7 @@ public SecurityFilterChain securityFilterChain(HttpSecurity http) throws Excepti public CorsConfigurationSource corsConfigurationSource() { CorsConfiguration configuration = new CorsConfiguration(); configuration.setAllowedOriginPatterns(List.of("*")); - configuration.setAllowedMethods(Arrays.asList("GET", "POST", "PUT", "DELETE", "OPTIONS")); + configuration.setAllowedMethods(Arrays.asList("GET", "POST", "PUT", "PATCH", "DELETE", "OPTIONS")); configuration.setAllowCredentials(true); configuration.setMaxAge(3600L); configuration.setAllowedHeaders(List.of("*"));