Skip to content

Commit

Permalink
Profile tags corrected (publiclab#2270)
Browse files Browse the repository at this point in the history
  • Loading branch information
SidharthBansal authored and jywarren committed Feb 8, 2018
1 parent 40ac420 commit 75a5ab6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion app/views/tag/_tags.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@
<span id="tag_<%= tag.id %>" class="label <%= label_name %>">
<a class="tag-name" href="/tag/<%= tag.name %>"><%= tag.name %></a>
<a data-confirm="Are you sure you want to delete it?" class="tag-delete" data-remote="true" href="/profile/tags/delete/<%= @user.id %>?name=<%= tag.name %>" data-method="delete">x</a>
<% if current_user && ( current_user.uid == tag.uid || current_user.role == "admin" || current_user.role == "moderator") %>
<a data-confirm="Are you sure you want to delete it?" class="tag-delete" data-remote="true" href="/profile/tags/delete/<%= @user.id %>?name=<%= tag.name %>" data-method="delete">x</a>
<% end %>
</span>
<% end %>
Expand Down

0 comments on commit 75a5ab6

Please sign in to comment.