fixed add to shopping when using ingredient headers

This commit is contained in:
vabene1111 2023-02-18 21:56:21 +01:00
parent 8d85800e2f
commit e33c3789b7

View File

@ -128,7 +128,7 @@ export default {
if (!this.recipe_servings) {
this.recipe_servings = result.data?.servings
}
this.steps.forEach(s => s.ingredients.filter(i => i.food.food_onhand === false).forEach(i => this.$set(i, 'checked', true)))
this.steps.forEach(s => s.ingredients.filter(i => i.food?.food_onhand === false).forEach(i => this.$set(i, 'checked', true)))
this.loading = false
})
.then(() => {