404 quand un ftag n'existe pas ou n'est pas trouvé dans les pages de filtrage par tag
This commit is contained in:
parent
fac41ff4f8
commit
6f502af4a0
1 changed files with 1 additions and 1 deletions
|
|
@ -92,7 +92,7 @@ class ProductsController extends Controller
|
|||
})
|
||||
->paginate(12);
|
||||
|
||||
$tag = Tag::where('slug', $tag_slug)->first();
|
||||
$tag = Tag::where('slug', $tag_slug)->firstOrFail();
|
||||
$search_title = $tag->label;
|
||||
|
||||
return view('search', compact('products', 'search_title', 'tag'));
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue