Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[fix] 기타 수정사항 적용 #85 #88

Merged
merged 3 commits into from
Jan 15, 2024
Merged

[fix] 기타 수정사항 적용 #85 #88

merged 3 commits into from
Jan 15, 2024

Conversation

tkdwns414
Copy link
Collaborator

Related Issue 📌

Description ✔️

  1. 단체 검색시 검색어 ""로 입력하였을 경우 400 에러를 띄워주도록 변경
  2. 유저가 BaseTimeEntity를 상속받도록 변경

@tkdwns414 tkdwns414 self-assigned this Jan 15, 2024
Comment on lines +51 to +57
@ExceptionHandler(value = {MissingServletRequestParameterException.class})
public ResponseEntity<ApiResponse<?>> handlerMissingServletRequestParameterException(Exception e) {
log.error("handlerMissingServletRequestParameterException() in GlobalExceptionHandler throw MissingServletRequestParameterException : {}", e.getMessage());
return ResponseEntity.status(HttpStatus.BAD_REQUEST)
.body(ApiResponse.fail(ErrorMessage.MISSING_REQUIRED_PARAMETER));
}

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

http code를 이제 responsebodyadvice에서 처리해서 나중에 한꺼번에 리팩토링 하면 좋을 것 같아요

@@ -69,7 +85,7 @@ public ResponseEntity<ApiResponse<?>> handleCustomException(CustomException e) {

@ExceptionHandler(Exception.class)
public ResponseEntity<ApiResponse<?>> handlerException(Exception e) {
log.error("handlerException() in GlobalExceptionHandler throw Exception : {}", e.getMessage());
log.error("handlerException() in GlobalExceptionHandler throw Exception : {} {}", e.getClass(), e.getMessage());
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exception 다 잡을 때까지 이렇게 e.getClass() 해 놓는 것 좋은 것 같습니다!

@Parkjyun Parkjyun merged commit 5b082b3 into develop Jan 15, 2024
1 check passed
@tkdwns414 tkdwns414 deleted the fix/82 branch January 18, 2024 17:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[fix] 기타 수정사항 적용
2 participants