From 25098a41a4c52c4bd66ab8152790baa95fecc919 Mon Sep 17 00:00:00 2001 From: Jeff Becker Date: Wed, 10 May 2017 13:50:34 -0400 Subject: [PATCH] update scraper this code will kill kittens --- service/scraper/scraper.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/service/scraper/scraper.go b/service/scraper/scraper.go index a7196b96..155e3409 100644 --- a/service/scraper/scraper.go +++ b/service/scraper/scraper.go @@ -153,7 +153,7 @@ func (sc *Scraper) Scrape() { swarms := make([]model.Torrent, 0, 128) now := time.Now().Add(0 - sc.interval).Unix() - err := db.ORM.Where("last_scrape < ?", now).Find(&swarms).Error + err := db.ORM.Where("last_scrape < ?", now).Or("last_scrape IS NULL").Find(&swarms).Error if err == nil { for swarms != nil { var scrape []model.Torrent