|
|
@@ -156,7 +156,11 @@ public class MetaGameCopyController extends BaseController {
|
|
|
@GetMapping("/sumPoint")
|
|
|
public MetaRestResult<MetaZombieFinishRecord> sumPoint() {
|
|
|
Long userId = SecurityUtils.getAuthenticatedUser().getId();
|
|
|
- int sumPoint = metaGameProcessRepo.sumPoint(userId, List.of(8746067L, 8734418L, 8734417L));
|
|
|
+ Long sum = metaGameProcessRepo.sumPoint(userId, List.of(8746067L, 8734418L, 8734417L));
|
|
|
+ if (Objects.isNull(sum)) {
|
|
|
+ return MetaRestResult.returnSuccess(new MetaZombieFinishRecord(userId, false, false, 0));
|
|
|
+ }
|
|
|
+ int sumPoint = sum.intValue();
|
|
|
int point = sysConfigService.getInt("zombie_point");
|
|
|
if (sumPoint < point) {
|
|
|
return MetaRestResult.returnSuccess(new MetaZombieFinishRecord(userId, false, false, sumPoint));
|