diff options
Diffstat (limited to 'crawler/shop_whiskyzone.go')
| -rw-r--r-- | crawler/shop_whiskyzone.go | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/crawler/shop_whiskyzone.go b/crawler/shop_whiskyzone.go index 2c1fb99..dbaf0ba 100644 --- a/crawler/shop_whiskyzone.go +++ b/crawler/shop_whiskyzone.go @@ -13,10 +13,7 @@ func (app *App) ScrapeWhiskyzone(shop Shop) []Angebot { Whiskys := []Angebot{} - c := colly.NewCollector( - colly.AllowedDomains("whiskyzone.de"), - colly.AllowedDomains("www.whiskyzone.de"), - ) + c := app.customCollector([]string{"whiskyzone.de", "www.whiskyzone.de"}) c.OnHTML(".product--info", func(e *colly.HTMLElement) { @@ -157,7 +154,10 @@ func (app *App) ScrapeWhiskyzone(shop Shop) []Angebot { }) - c.Visit(Shop_url) + err := c.Visit(Shop_url) + if err != nil { + Warn(nil, shop.Name+": "+err.Error()) + } return Whiskys } |
