diff --git a/compensation/forms/eco_account.py b/compensation/forms/eco_account.py index 9e74e839..0352383c 100644 --- a/compensation/forms/eco_account.py +++ b/compensation/forms/eco_account.py @@ -175,7 +175,7 @@ class EditEcoAccountForm(NewEcoAccountForm): def is_valid(self): valid = super().is_valid() - deductable_surface = self.cleaned_data.get("surface") + deductable_surface = self.cleaned_data.get("surface") or 0.0 deduction_surface_sum = self.instance.get_deductions_surface() if deductable_surface < deduction_surface_sum: self.add_error(