artists: hide other names of banned artists on index page.
Don't show other names of banned artists on the /artists page to anonymous users. Hides potentially sensitive information from Google and logged out users.
This commit is contained in:
@@ -13,8 +13,10 @@
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% t.column "Other Names", td: {class: "col-expand"} do |artist| %>
|
||||
<% artist.other_names.each do |name| %>
|
||||
<%= link_to name, artists_path(search: { any_name_matches: name }), class: "artist-other-name", rel: "nofollow" %>
|
||||
<% unless artist.is_banned? && !policy(artist).can_view_banned? %>
|
||||
<% artist.other_names.each do |name| %>
|
||||
<%= link_to name, artists_path(search: { any_name_matches: name }), class: "artist-other-name", rel: "nofollow" %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% t.column "Status" do |artist| %>
|
||||
|
||||
Reference in New Issue
Block a user