Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 2 additions & 7 deletions src/includes/replies/template.php
Original file line number Diff line number Diff line change
Expand Up @@ -1798,14 +1798,9 @@ function bbp_get_reply_admin_links( $args = array() ) {

// See if links need to be unset
$reply_status = bbp_get_reply_status( $r['id'] );
if ( in_array( $reply_status, array( bbp_get_spam_status_id(), bbp_get_trash_status_id(), bbp_get_pending_status_id() ), true ) ) {

// Spam link shouldn't be visible on trashed topics
if ( bbp_get_trash_status_id() === $reply_status ) {
unset( $r['links']['spam'] );

if ( in_array( $reply_status, array( bbp_get_spam_status_id(), bbp_get_pending_status_id() ), true ) ) {
// Trash link shouldn't be visible on spam topics
} elseif ( bbp_get_spam_status_id() === $reply_status ) {
if ( bbp_get_spam_status_id() === $reply_status ) {
unset( $r['links']['trash'] );
}
}
Expand Down