重构,升级异常拦截器为 0.0.5-SNAPSHOT。

This commit is contained in:
2022-12-14 14:30:54 +08:00
parent 71438901a0
commit d398800ce4
6 changed files with 22 additions and 9 deletions

View File

@@ -0,0 +1,15 @@
package xyz.zhouxy.plusone.validator;
import org.springframework.web.bind.annotation.RestControllerAdvice;
import xyz.zhouxy.plusone.constant.ErrorCodeConsts;
import xyz.zhouxy.plusone.exception.handler.BaseExceptionHandler;
@RestControllerAdvice
public class InvalidInputExceptionHandler extends BaseExceptionHandler {
protected InvalidInputExceptionHandler() {
super(new ExceptionInfoHolder(ErrorCodeConsts.DEFAULT_ERROR_CODE));
set(InvalidInputException.class, InvalidInputException.ERROR_CODE, "无效的用户输入");
}
}