BUGFIX: 用户被删除的情况下,获取该云过户原来的评论,点赞等记录

This commit is contained in:
2025-04-28 15:26:07 +08:00
parent 58af5c5570
commit aa0778958e

View File

@@ -135,7 +135,7 @@ public class MessageCenterServiceImpl extends ServiceImpl<NotificationMapper, No
notificationVO.setIsRead(1); notificationVO.setIsRead(1);
} }
}else { }else {
String avatar = StringUtil.isNullOrEmpty(senderAccount.getAvatar()) ? CommonConstant.DEFAULT_AVATAR : senderAccount.getAvatar(); String avatar = Objects.isNull(senderAccount) || StringUtil.isNullOrEmpty(senderAccount.getAvatar()) ? CommonConstant.DEFAULT_AVATAR : senderAccount.getAvatar();
notificationVO.setAvatar(minioUtil.getPreSignedUrl(avatar, CommonConstant.MINIO_IMAGE_EXPIRE_TIME)); notificationVO.setAvatar(minioUtil.getPreSignedUrl(avatar, CommonConstant.MINIO_IMAGE_EXPIRE_TIME));
} }
return notificationVO; return notificationVO;