Skip to content

Commit

Permalink
feat: cors allow origins
Browse files Browse the repository at this point in the history
  • Loading branch information
Youthhing committed Sep 6, 2024
1 parent 06860a8 commit 4c6f13c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/java/team/flight/backend/config/WebConfig.java
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public class WebConfig implements WebMvcConfigurer {
public void addCorsMappings(CorsRegistry registry) {
registry.addMapping("/**")
.allowedMethods("*")
.allowedOrigins("http://localhost:3000", "https://www.chatppt.site")
.allowedOrigins("http://localhost:3000", "https://www.chatppt.site", "https://api.chatppt.site")
.allowedHeaders("Content-Type", "Authorization", "Accept", "X-Requested-With", "Origin", "X-CSRF-Token")
.maxAge(3600L)
.allowCredentials(true);
Expand Down

0 comments on commit 4c6f13c

Please sign in to comment.