From 0fb5d31a22b78e9fb7712bb3c098e5af8cd12499 Mon Sep 17 00:00:00 2001 From: Brian Choromanski Date: Fri, 10 Apr 2026 21:04:30 -0400 Subject: [PATCH] fix: Unchecking took in recipe (#7439) Co-authored-by: Michael Genson <71845777+michael-genson@users.noreply.github.com> --- .../RecipePageParts/RecipePageIngredientToolsView.vue | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/frontend/app/components/Domain/Recipe/RecipePage/RecipePageParts/RecipePageIngredientToolsView.vue b/frontend/app/components/Domain/Recipe/RecipePage/RecipePageParts/RecipePageIngredientToolsView.vue index ae77cb54e..68f2fee8b 100644 --- a/frontend/app/components/Domain/Recipe/RecipePage/RecipePageParts/RecipePageIngredientToolsView.vue +++ b/frontend/app/components/Domain/Recipe/RecipePage/RecipePageParts/RecipePageIngredientToolsView.vue @@ -62,17 +62,18 @@ const toolStore = isOwnGroup.value ? useToolStore() : null; const { user } = usePageUser(); const { isEditMode } = usePageState(props.recipe.slug); -const recipeTools = computed(() => { +const recipeTools = ref([]); +watch(() => props.recipe.tools, () => { if (!(user.householdSlug && toolStore)) { - return props.recipe.tools.map(tool => ({ ...tool, onHand: false }) as RecipeToolWithOnHand); + recipeTools.value = props.recipe.tools.map(tool => ({ ...tool, onHand: false }) as RecipeToolWithOnHand); } else { - return props.recipe.tools.map((tool) => { + recipeTools.value = props.recipe.tools.map((tool) => { const onHand = tool.householdsWithTool?.includes(user.householdSlug) || false; return { ...tool, onHand } as RecipeToolWithOnHand; }); } -}); +}, { immediate: true }); function updateTool(index: number) { if (user.id && user.householdSlug && toolStore) {