|
@@ -44,7 +44,7 @@ public class SmsService {
|
|
|
}
|
|
|
if (!debug && !aliyunService.afs(appkey, scene, token, sessionId, sig, ip)) {
|
|
|
logger.warn("人机验证失败:{}", token);
|
|
|
- throw new MtaException("人机验证失败");
|
|
|
+ throw new MtaException("人机验证失败,请刷新页面后重试");
|
|
|
}
|
|
|
// 检查号码
|
|
|
logger.info("检查手机号: {}", phone);
|
|
@@ -84,7 +84,7 @@ public class SmsService {
|
|
|
logger.warn("每小时限制5条: {}", phone);
|
|
|
return false;
|
|
|
}
|
|
|
- RedisUtil.set(key, count, 1, TimeUnit.HOURS);
|
|
|
+ RedisUtil.set(key, count+1, 1, TimeUnit.HOURS);
|
|
|
}else {
|
|
|
RedisUtil.set(key, 1, 1, TimeUnit.HOURS);
|
|
|
}
|
|
@@ -97,7 +97,7 @@ public class SmsService {
|
|
|
logger.warn("每天限制10条: {}", phone);
|
|
|
return false;
|
|
|
}
|
|
|
- RedisUtil.set(key, count, 1, TimeUnit.DAYS);
|
|
|
+ RedisUtil.set(key, count+1, 1, TimeUnit.DAYS);
|
|
|
}else {
|
|
|
RedisUtil.set(key, 1, 1, TimeUnit.DAYS);
|
|
|
}
|