diff options
author | Adam Mathes <adam@trenchant.org> | 2017-01-24 21:37:11 -0800 |
---|---|---|
committer | Adam Mathes <adam@trenchant.org> | 2017-01-24 21:37:11 -0800 |
commit | 27c88be8c573db005c7b947e5120af5feec9c1cb (patch) | |
tree | afee6d7198b0ef79cf0625cd793cc889ae610d2e /crawler | |
parent | 38b71e64f6dfda4e49b261f3ac1465e268857311 (diff) | |
download | neko-27c88be8c573db005c7b947e5120af5feec9c1cb.tar.gz neko-27c88be8c573db005c7b947e5120af5feec9c1cb.tar.bz2 neko-27c88be8c573db005c7b947e5120af5feec9c1cb.zip |
print item creation errors during crawl
Diffstat (limited to 'crawler')
-rw-r--r-- | crawler/crawler.go | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/crawler/crawler.go b/crawler/crawler.go index e3e4aeb..faf0b70 100644 --- a/crawler/crawler.go +++ b/crawler/crawler.go @@ -57,7 +57,10 @@ func CrawlFeed(f *feed.Feed, ch chan<- string) { item.Description = i.Summary } item.FeedId = f.Id - item.Create() + err := item.Create() + if err != nil { + log.Println(err) + } } ch <- "successfully crawled " + f.Url } |