release- 修复userInfo的point=0的情况

release-2024-08-08
huangyawei 4 months ago
parent b4418c8b45
commit f6b7ca9ceb

@ -166,7 +166,7 @@ public class UserPointLogService {
// 更新用户积分,获取用户信息并累加积分得分
// 对用户进行积分计算
UserInfo userInfo = userInfoDao.findById(userPointLog.getUserId()).get();
Integer point = userInfo.getPoint();
Integer point = userInfo.getPoint() == null ? 0 : userInfo.getPoint();
point += userPointLog.getScore();
userInfo.setPoint(point);
// 更新用户积分信息

Loading…
Cancel
Save