diff --git a/src/main/java/org/kkumulkkum/server/advice/GlobalExceptionHandler.java b/src/main/java/org/kkumulkkum/server/advice/GlobalExceptionHandler.java index 7bcbbcc..15329b2 100644 --- a/src/main/java/org/kkumulkkum/server/advice/GlobalExceptionHandler.java +++ b/src/main/java/org/kkumulkkum/server/advice/GlobalExceptionHandler.java @@ -4,6 +4,7 @@ import org.kkumulkkum.server.exception.*; import org.kkumulkkum.server.exception.code.*; import org.springframework.http.ResponseEntity; +import org.springframework.http.converter.HttpMessageNotReadableException; import org.springframework.web.HttpRequestMethodNotSupportedException; import org.springframework.web.bind.MethodArgumentNotValidException; import org.springframework.web.bind.MissingRequestHeaderException; @@ -109,7 +110,11 @@ public ResponseEntity handleNoPageFoundException(HttpRequestM .body(BusinessErrorCode.METHOD_NOT_ALLOWED); } - @ExceptionHandler(value = {HandlerMethodValidationException.class, MethodArgumentNotValidException.class}) + @ExceptionHandler(value = { + HandlerMethodValidationException.class, + MethodArgumentNotValidException.class, + HttpMessageNotReadableException.class + }) public ResponseEntity handleValidationException(Exception e) { log.warn("GlobalExceptionHandler catch MethodArgumentNotValidException : {}", e.getMessage()); return ResponseEntity