/**
 * Get the URL for deleting the current thread.
 *
 * @since 1.5.0
 *
 * @return string URL
 */
function bp_get_the_thread_delete_link()
{
    /**
     * Filters the URL for deleting the current thread.
     *
     * @since 1.0.0
     *
     * @param string $value URL for deleting the current thread.
     * @param string $value Text indicating action being executed.
     */
    return apply_filters('bp_get_message_thread_delete_link', wp_nonce_url(bp_loggedin_user_domain() . bp_get_messages_slug() . '/inbox/delete/' . bp_get_the_thread_id(), 'messages_delete_thread'));
}
 function private_message_print_links()
 {
     $report_links = array();
     foreach ((array) $GLOBALS['thread_template']->thread->sender_ids as $sender_id) {
         if ($sender_id != bp_loggedin_user_id()) {
             $report_links[] = bpModFrontend::get_link(array('type' => 'private_message', 'id' => bp_get_the_thread_id(), 'id2' => $sender_id, 'unflagged_text' => bp_core_get_user_displayname($sender_id), 'flagged_text' => bp_core_get_user_displayname($sender_id), 'custom_class' => 'button'));
         }
     }
     if (!count($report_links)) {
         return;
     }
     echo '<p class="bp-mod-pm-thread-links">';
     printf(__('Flag as inappropriate messages by: %s', 'bp-moderation'), join(' ', $report_links));
     echo '</p>';
 }
function bp_get_the_thread_delete_link()
{
    global $bp;
    return apply_filters('bp_get_message_thread_delete_link', wp_nonce_url(bp_loggedin_user_domain() . $bp->messages->slug . '/inbox/delete/' . bp_get_the_thread_id(), 'messages_delete_thread'));
}
function bp_the_thread_id() {
	echo bp_get_the_thread_id();
}