Skip to content

Commit

Permalink
Merge pull request #149 from Team-MindWay/148-cors-resolve
Browse files Browse the repository at this point in the history
🔀 :: cors 해결
  • Loading branch information
Umjiseung authored May 10, 2024
2 parents f0590b6 + 0044c17 commit a42df99
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ public class EventScheduler {
private final ChangeNowToPastService changeNowToPastService;
private final ChangePendingToNowService changePendingToNowService;

@Scheduled(cron = "0 0 0 * *", zone = "Asia/Seoul")
@Scheduled(cron = "0 0 0 * * *", zone = "Asia/Seoul")
public void changeNowToPast() {
changeNowToPastService.execute();
}

@Scheduled(cron = "0 0 0 * *", zone = "Asia/Seoul")
@Scheduled(cron = "0 0 0 * * *", zone = "Asia/Seoul")
public void changePendingToNow() {
changePendingToNowService.execute();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,14 @@
@EnableWebSecurity
public class SecurityConfig {
private final JwtProvider jwtProvider;
private final CorsFilter corsFilter;
private final JwtAuthenticationEntryPoint jwtAuthenticationEntryPoint;
private final JwtAccessDeniedHandler jwtAccessDeniedHandler;

@Bean
public SecurityFilterChain filterChain(HttpSecurity http) throws Exception {
http
.csrf(AbstractHttpConfigurer::disable)
.addFilterBefore(corsFilter, UsernamePasswordAuthenticationFilter.class)
.cors(AbstractHttpConfigurer::disable)

.exceptionHandling(exceptionConfig ->
exceptionConfig.authenticationEntryPoint(jwtAuthenticationEntryPoint)
Expand Down

0 comments on commit a42df99

Please sign in to comment.