mirror of
https://github.com/TandoorRecipes/recipes.git
synced 2026-01-07 07:08:03 -05:00
fixed ingredient to string plural
This commit is contained in:
@@ -681,7 +681,7 @@ class Ingredient(ExportModelOperationsMixin('ingredient'), models.Model, Permiss
|
|||||||
if self.always_use_plural_unit and self.unit.plural_name not in (None, "") and not self.no_amount:
|
if self.always_use_plural_unit and self.unit.plural_name not in (None, "") and not self.no_amount:
|
||||||
unit = self.unit.plural_name
|
unit = self.unit.plural_name
|
||||||
else:
|
else:
|
||||||
if self.amount > 1 and self.unit.plural_name not in (None, "") and not self.no_amount:
|
if self.amount > 1 and self.unit is not None and self.unit.plural_name not in (None, "") and not self.no_amount:
|
||||||
unit = self.unit.plural_name
|
unit = self.unit.plural_name
|
||||||
else:
|
else:
|
||||||
unit = str(self.unit)
|
unit = str(self.unit)
|
||||||
|
|||||||
Reference in New Issue
Block a user