init
This commit is contained in:
@@ -91,9 +91,9 @@ public class SmsVerifyServiceImpl extends ServiceImpl<SmsVerifyMapper,SmsVerify>
|
||||
.gt(SmsVerify::getOverTime, now)
|
||||
.last("limit 1"));
|
||||
if(one != null){
|
||||
long diff = now.until(one.getCreateTime(), ChronoUnit.SECONDS);
|
||||
if(diff < 60){
|
||||
throw new ServiceException("请"+diff+"秒之后再重试发送!");
|
||||
long diff = one.getCreateTime().until(now, ChronoUnit.SECONDS);
|
||||
if(diff < 100){
|
||||
throw new ServiceException("请"+(100-diff)+"秒之后再重试发送!");
|
||||
}
|
||||
}
|
||||
long count = userInfoService.count(Wrappers.lambdaQuery(UserInfo.class).eq(UserInfo::getRegIp, clientIP));
|
||||
|
||||
Reference in New Issue
Block a user