增加对自定义异常炮火

This commit is contained in:
wulin 2020-12-18 11:58:19 +08:00
parent 5948f4eee5
commit 87885eca0c

View File

@ -1,6 +1,7 @@
package com.lz.common.aspect;
import com.alibaba.fastjson.JSON;
import com.lz.common.exception.RRException;
import com.lz.common.utils.OrderUtil;
import com.lz.common.utils.R;
import com.lz.common.utils.ServletUtils;
@ -111,8 +112,13 @@ public class LogAspect {
result = point.proceed();
return result;
} catch (Exception e) {
if(e instanceof RRException){
result = R.error(((RRException) e).getMsg());
}else{
result = R.error();
}
logger.error("controller error.", e);
result = R.error();
} finally {
if(cm.toString().toLowerCase().contains("captcha")){
logger.info(StringUtil.appendStrs(