maxiaoshan 3 years ago
parent
commit
3adfd337f5
1 changed files with 3 additions and 2 deletions
  1. 3 2
      src/spider/spider.go

+ 3 - 2
src/spider/spider.go

@@ -375,9 +375,10 @@ func (s *Spider) DownListPageItem() (errs interface{}) {
 		"endpage":    start,
 		"date":       sDate,
 	}
-	inc := map[string]interface{}{}
+	inc := map[string]interface{}{
+		"alltimes": 1,
+	}
 	if downloadAllNum > 0 {
-		inc["alltimes"] = 1
 		rate := float64(downloadAllNum-repeatAllNum) / float64(downloadAllNum)
 		rate, _ = strconv.ParseFloat(fmt.Sprintf("%.2f", rate), 64)
 		if rate == 1.0 {