Skip to content

Commit

Permalink
refactor: cors 설정 재수정
Browse files Browse the repository at this point in the history
  • Loading branch information
capDoYeonLee committed Dec 5, 2024
1 parent 6c2d465 commit 292d0e6
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,12 @@ public WebMvcConfig(@Value("${cors.allow-origin.urls}") final String allowOrigin
.map(String::trim)
.collect(Collectors.toList());
}

@Override
public void addCorsMappings(CorsRegistry registry) {
String[] patterns = allowOriginUrlPatterns.toArray(String[]::new);

registry
//.addMapping("/api/**")
.addMapping("/**")
.allowedOriginPatterns(patterns)
.allowedHeaders("*")
Expand All @@ -39,5 +39,4 @@ public void addCorsMappings(CorsRegistry registry) {
.allowCredentials(true)
.maxAge(MAX_AGE_SECS);
}

}

0 comments on commit 292d0e6

Please sign in to comment.