diff --git a/inflatinator/scrapers.py b/inflatinator/scrapers.py index e2b6652..82767e0 100644 --- a/inflatinator/scrapers.py +++ b/inflatinator/scrapers.py @@ -40,7 +40,7 @@ def ah_get_by_gtin(gtin13): units_description = ah_prod['salesUnitSize'] units = 1 - if (m := re.search(r'^(\d+)', units_description)): + if (m := re.search(r'^\s*(\d+)', units_description)): units = int(m[1]) return Product(