posts/show: fix 'Hide from queue' option in sidebar.

Fix 'Hide from queue' option appearing on deleted posts, but not on
pending or flagged posts.
This commit is contained in:
evazion
2018-08-14 12:48:13 -05:00
parent 41a7923ade
commit d7ec28b804
2 changed files with 1 additions and 31 deletions

View File

@@ -39,9 +39,8 @@
<li><%= link_to "Delete", confirm_delete_moderator_post_post_path(:post_id => post.id) %></li>
<% end %>
<% if post.is_flagged? || post.is_pending? %>
<% if post.is_approvable? && !post.is_deleted? %>
<li><%= link_to "Approve", moderator_post_approval_path(:post_id => post.id), :remote => true, :method => :post, :id => "approve", :"data-shortcut" => "shift+o", :"data-confirm" => "Are you sure you want to approve this post?" %></li>
<% else %>
<li><%= link_to "Hide from queue", moderator_post_disapproval_path(post_disapproval: { post_id: post.id, reason: "disinterest" }), remote: true, method: :post, id: "disapprove" %></li>
<% end %>