Skip to content

Commit

Permalink
[hotfix] swagger 접속 안되는 문제 해결
Browse files Browse the repository at this point in the history
  • Loading branch information
JunRain2 committed Jun 5, 2024
1 parent a49390c commit d65cfc0
Showing 1 changed file with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -66,13 +66,19 @@ private void checkRefreshTokenAndReIssueAccessToken(HttpServletResponse response

private void checkAccessTokenAndAuthentication(HttpServletRequest request, HttpServletResponse response,
FilterChain filterChain) throws ServletException, IOException {
// TODO swagger 전달을 위한 코드 추후 제거
try {
jwtService.extractAccessToken(request);
} catch (Exception e) {
filterChain.doFilter(request, response);
}

try {
String email = jwtService.getEmail(request);
memberRepository.findByEmail(email).ifPresent(this::saveAuthentication);
filterChain.doFilter(request, response);
} catch (Exception e) {
response.setStatus(SC_FORBIDDEN);
} finally {
filterChain.doFilter(request, response);
}
}

Expand Down

0 comments on commit d65cfc0

Please sign in to comment.