rdluck 4 years ago
parent
commit
f36a574e14
1 changed files with 2 additions and 2 deletions
  1. 2 2
      services/article.go

+ 2 - 2
services/article.go

@@ -49,7 +49,7 @@ func GetReportContentTextSub(content string) (contentSub string, err error) {
 				return
 			}
 			text := s.Text()
-			if !strings.Contains(text, "访谈时间") && !strings.Contains(text, "纪要详情") {
+			if text != "" && !strings.Contains(text, "访谈时间") && !strings.Contains(text, "纪要详情") {
 				n++
 				contentSub = contentSub + s.Text()
 			}
@@ -64,7 +64,7 @@ func GetReportContentTextSub(content string) (contentSub string, err error) {
 					return
 				}
 				text := s.Text()
-				if !strings.Contains(text, "访谈时间") && !strings.Contains(text, "纪要详情") {
+				if text != "" && !strings.Contains(text, "访谈时间") && !strings.Contains(text, "纪要详情") {
 					n++
 					contentSub = contentSub + s.Text()
 				}