修复防重复提交bug

This commit is contained in:
paulGao 2022-05-05 11:57:05 +08:00
parent 26c9160c75
commit f4a7d8ea92

View File

@ -38,7 +38,7 @@ public class PreventDuplicateSubmissionsInterceptor {
try {
Long count = cache.incr(getParams(), preventDuplicateSubmissions.expire());
//如果超过1或者设置的参数则表示重复提交了
if (count.intValue() >= preventDuplicateSubmissions.expire()) {
if (count.intValue() >= 1) {
throw new ServiceException(ResultCode.LIMIT_ERROR);
}
}