feat(search): force display dnp entries even if found no images (#223)

This commit is contained in:
mdashlw 2024-04-06 23:05:32 +03:00 committed by GitHub
parent 3714ae115c
commit cc32f5d3b9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,5 +1,5 @@
= cond do
- Enum.any?(@images) ->
- Enum.any?(@images) or Enum.any?(@tags, &Enum.any?(elem(&1, 0).dnp_entries)) ->
= render PhilomenaWeb.ImageView, "index.html", conn: @conn, tags: @tags, images: @images, header: "Searching for #{@conn.params["q"]}", route: fn p -> Routes.search_path(@conn, :index, p) end, scope: scope(@conn)
- assigns[:error] ->