fix: 修复逻辑错误

This commit is contained in:
cjy 2026-01-14 17:04:41 +08:00
parent 6b52775913
commit dfb2e5e037

View File

@ -71,7 +71,7 @@ func CreateCompetitiveReport(ctx *gin.Context) {
return
}
if req.ReportContent != "" && req.ImageUrl != "" {
if req.ReportContent == "" || req.ImageUrl == "" {
err = errors.New("报告内容和图片不能同时为空")
service.Error(ctx, err)
return