From 47ee2f721f552d0b65159516f7420d14a7880bbd Mon Sep 17 00:00:00 2001 From: horus Date: Sat, 17 Feb 2018 19:07:08 +0100 Subject: Minor improvement in logging. (crawler) --- crawler/shop_whiskyde.go | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'crawler/shop_whiskyde.go') diff --git a/crawler/shop_whiskyde.go b/crawler/shop_whiskyde.go index ffbbe08..7ad7fd7 100644 --- a/crawler/shop_whiskyde.go +++ b/crawler/shop_whiskyde.go @@ -23,6 +23,10 @@ func (app *App) ScrapeWhiskyde(shop Shop) []Angebot { } W := Angebot{} + + W.Shop = shop.Id + W.Spirit_type = "Whisky" + whisky_name := e.ChildAttr("a", "title") W.Name = whisky_name whisky_url := strings.Replace(e.ChildAttr("a", "href"), "?&searchorigin=2", "", 1) @@ -95,9 +99,6 @@ func (app *App) ScrapeWhiskyde(shop Shop) []Angebot { return } - W.Shop = shop.Id - W.Spirit_type = "Whisky" - W.Base_price, err = convert_price(e.ChildText(".article-unitprice-default")) if err != nil { W.error_msg = err.Error() -- cgit v1.2.3