Skip to content

Commit 6be0541

Browse files
authored
Only show link to url if present (#609)
1 parent edc5c4a commit 6be0541

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

app/views/entries/index.html.erb

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,11 @@
3232
<%= link_to entry, class: 'table__link', aria: { label: t('.show') } do %>
3333
<%= inline_svg_tag 'images/icons/eye.svg', class: 'icon' %>
3434
<% end %>
35-
<%= link_to entry.url, class: 'table__link', aria: { label: t('.go_to_original') } do %>
36-
<%= inline_svg_tag 'images/icons/arrow-top-right-on-square.svg', class: 'icon' %>
37-
<% end %>
35+
<%- if entry.url.present? %>
36+
<%= link_to entry.url, class: 'table__link', aria: { label: t('.go_to_original') } do %>
37+
<%= inline_svg_tag 'images/icons/arrow-top-right-on-square.svg', class: 'icon' %>
38+
<% end %>
39+
<%- end %>
3840
<% end %>
3941
</tr>
4042
<%- end %>

0 commit comments

Comments
 (0)