diff --git a/resources/views/components/ingredient-picker.blade.php b/resources/views/components/ingredient-picker.blade.php
index e78a9a0..90b0f4c 100644
--- a/resources/views/components/ingredient-picker.blade.php
+++ b/resources/views/components/ingredient-picker.blade.php
@@ -91,6 +91,7 @@
this.$refs.ingredients_type.value = selected.dataset.type;
this.$refs.ingredients_name.value = selected.dataset.name + (selected.dataset.detail ? `, ${selected.dataset.detail}` : '');
this.searching = false;
+ this.results = [];
}
}
}
diff --git a/resources/views/recipes/edit.blade.php b/resources/views/recipes/edit.blade.php
index 42b393f..2cdd90d 100644
--- a/resources/views/recipes/edit.blade.php
+++ b/resources/views/recipes/edit.blade.php
@@ -72,15 +72,17 @@
-
- @foreach($ingredients as $ingredient)
+
+ @forelse($ingredients as $ingredient)
@include('recipes.partials.ingredient-input', $ingredient)
- @endforeach
-
+ @empty
@include('recipes.partials.ingredient-input')
-
-
-