mirror of
https://github.com/PlayEdu/PlayEdu
synced 2025-07-25 02:39:31 +08:00
优化学员学习记录的错误提示
This commit is contained in:
parent
5e4c35f9bf
commit
893ab33811
@ -129,7 +129,7 @@ public class HourController {
|
|||||||
String lockKey = String.format("record:%d", FCtx.getId());
|
String lockKey = String.format("record:%d", FCtx.getId());
|
||||||
boolean tryLock = redisDistributedLock.tryLock(lockKey, 5, TimeUnit.SECONDS);
|
boolean tryLock = redisDistributedLock.tryLock(lockKey, 5, TimeUnit.SECONDS);
|
||||||
if (!tryLock) {
|
if (!tryLock) {
|
||||||
return JsonResponse.error("请稍后再试");
|
return JsonResponse.success();
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
@ -166,7 +166,7 @@ public class HourController {
|
|||||||
String lockKey = String.format("ping:%d", FCtx.getId());
|
String lockKey = String.format("ping:%d", FCtx.getId());
|
||||||
boolean tryLock = redisDistributedLock.tryLock(lockKey, 5, TimeUnit.SECONDS);
|
boolean tryLock = redisDistributedLock.tryLock(lockKey, 5, TimeUnit.SECONDS);
|
||||||
if (!tryLock) {
|
if (!tryLock) {
|
||||||
return JsonResponse.error("请稍后再试");
|
return JsonResponse.success();
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user