From 01e78baecfc6af9586d809a3029c9ae58e827b34 Mon Sep 17 00:00:00 2001 From: vabene1111 Date: Tue, 18 Nov 2025 15:48:39 +0100 Subject: [PATCH] fixed property helper error --- cookbook/helper/property_helper.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cookbook/helper/property_helper.py b/cookbook/helper/property_helper.py index 3e06164bb..1c9481835 100644 --- a/cookbook/helper/property_helper.py +++ b/cookbook/helper/property_helper.py @@ -56,7 +56,7 @@ class FoodPropertyHelper: if p.property_type == pt and p.property_amount is not None: has_property_value = True for c in conversions: - if c.unit == i.food.properties_food_unit: + if c.unit == i.food.properties_food_unit and i.food.properties_food_amount != 0: found_property = True computed_properties[pt.id]['total_value'] += (c.amount / i.food.properties_food_amount) * p.property_amount computed_properties[pt.id]['food_values'] = self.add_or_create(