|
@@ -123,7 +123,7 @@ public class UserService {
|
|
|
Boolean useCollectionPic, Boolean riskWarning, Integer level) {
|
|
Boolean useCollectionPic, Boolean riskWarning, Integer level) {
|
|
|
User user = userRepo.findById(userId).orElseThrow(new BusinessException("用户不存在"));
|
|
User user = userRepo.findById(userId).orElseThrow(new BusinessException("用户不存在"));
|
|
|
if (StringUtils.isNotBlank(nickname)) {
|
|
if (StringUtils.isNotBlank(nickname)) {
|
|
|
- if (!user.getNickname().equals(nickname)) {
|
|
|
|
|
|
|
+ if (!nickname.equals(user.getNickname())) {
|
|
|
if (!contentAuditService.auditText(nickname)) {
|
|
if (!contentAuditService.auditText(nickname)) {
|
|
|
throw new BusinessException("昵称包含非法内容");
|
|
throw new BusinessException("昵称包含非法内容");
|
|
|
}
|
|
}
|
|
@@ -140,7 +140,7 @@ public class UserService {
|
|
|
user.setBg(bg);
|
|
user.setBg(bg);
|
|
|
}
|
|
}
|
|
|
if (StringUtils.isNotBlank(intro)) {
|
|
if (StringUtils.isNotBlank(intro)) {
|
|
|
- if (!user.getIntro().equals(intro)) {
|
|
|
|
|
|
|
+ if (!intro.equals(user.getIntro())) {
|
|
|
if (!contentAuditService.auditText(nickname)) {
|
|
if (!contentAuditService.auditText(nickname)) {
|
|
|
throw new BusinessException("简介包含非法内容");
|
|
throw new BusinessException("简介包含非法内容");
|
|
|
}
|
|
}
|