Skip to content
Snippets Groups Projects

handle differently

Merged Tucker Gary Siegel requested to merge update into develop
2 files
+ 7
2
Compare changes
  • Side-by-side
  • Inline
Files
2
@@ -55,10 +55,9 @@ public class CustomExceptionHandler {
@ExceptionHandler(BindException.class)
protected ResponseEntity<Object> handleBindException(BindException ex, WebRequest request) {
DawnException wrapped = new DawnException(BaseExceptions.BAD_REQUEST, ex);
FieldError err = ex.getFieldError();
wrapped.setDescription("Value " + err.getRejectedValue() + " is invalid for field " + err.getField());
DawnException wrapped = new DawnException(BaseExceptions.BAD_REQUEST, ex, "Value " + err.getRejectedValue() + " is invalid for field " + err.getField());
return returnDawnException(wrapped);
}
Loading