diff --git a/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/command/dynamic/DynamicReportCmdExe.java b/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/command/dynamic/DynamicReportCmdExe.java index 6b805da9..6e3d1280 100644 --- a/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/command/dynamic/DynamicReportCmdExe.java +++ b/rc-service/rc-service-other/other-application/src/main/java/com/red/circle/other/app/command/dynamic/DynamicReportCmdExe.java @@ -8,6 +8,7 @@ import com.red.circle.other.infra.database.rds.service.dynamic.DynamicContentSer import com.red.circle.other.infra.database.rds.service.dynamic.DynamicReportService; import com.red.circle.other.inner.asserts.DynamicErrorCode; import com.red.circle.tool.core.date.TimestampUtils; +import com.red.circle.tool.core.text.StringUtils; import lombok.RequiredArgsConstructor; import org.springframework.stereotype.Component; @@ -38,7 +39,7 @@ public class DynamicReportCmdExe { dynamicReportService.save(new DynamicReport() .setApprovalStatus(0) .setDynamicContentId(content.getId()) - .setReportedContent(cmd.getReportedContent().replaceFirst(",", "")) + .setReportedContent(StringUtils.isNotBlank(cmd.getReportedContent()) ? cmd.getReportedContent().replaceFirst(",", "") : "") .setReportedUrls(cmd.getImageUrls()) .setReportedUserId(content.getCreateUser()) .setReportUserId(cmd.getReqUserId())