From 7b8dd3ff40ac6953fc104369597642207f73c001 Mon Sep 17 00:00:00 2001 From: Piotr Kus Date: Wed, 24 Jun 2026 22:31:18 +0200 Subject: [PATCH] * Error fix --- .../src/components/recipes/DietMealPreviewModal.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/meal-plan-frontend/src/components/recipes/DietMealPreviewModal.tsx b/meal-plan-frontend/src/components/recipes/DietMealPreviewModal.tsx index 067dfda..f796527 100644 --- a/meal-plan-frontend/src/components/recipes/DietMealPreviewModal.tsx +++ b/meal-plan-frontend/src/components/recipes/DietMealPreviewModal.tsx @@ -23,8 +23,8 @@ function toRecipeDetail(meal: DietGeneratorDraftMeal): RecipeDetailModel { ingredients: (meal.ingredients ?? []).map((ingredient) => ({ id: ingredient.id, name: ingredient.name, - amountGrams: ingredient.amountGrams, - unit: ingredient.unit, + amountGrams: ingredient.amountGrams ?? null, + unit: ingredient.unit ?? null, sortOrder: ingredient.sortOrder, catalogItemId: null, })),