Skip to content

Commit

Permalink
Fix [#51] cors 코드 수정 (#52)
Browse files Browse the repository at this point in the history
  • Loading branch information
geniusYoo authored Jul 14, 2024
2 parents f62213e + 0d498de commit fc0dba0
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ public class WebSecurityConfig implements WebMvcConfigurer {
@Override
public void addCorsMappings(CorsRegistry registry) {
registry.addMapping("/**") //* *모든 경로에 대해*
.allowedOrigins("https://localhost:5173", "http://localhost:5173")
.allowedOrigins("*")
.allowedHeaders("*")
.allowedMethods(HttpMethod.GET.name(), HttpMethod.POST.name()) //* *허용할* *HTTP* *메소드 목록*
.allowedMethods("GET", "POST", "DELETE", "PUT", "PATCH", "OPTIONS") //* *허용할* *HTTP* *메소드 목록*
.allowCredentials(true)
.maxAge(3000);
}
Expand Down

0 comments on commit fc0dba0

Please sign in to comment.