Make WordPress Core

Ticket #28026: 28026.patch

File 28026.patch, 1.0 KB (added by lpointet, 10 years ago)
  • wp-includes/link-template.php

        Index: wp-includes/link-template.php
     
    15391539         * @param bool   $in_same_term   Whether post should be in a same taxonomy term.
    15401540         * @param array  $excluded_terms Array of excluded term IDs.
    15411541         */
    1542         $where = apply_filters( "get_{$adjacent}_post_where", $wpdb->prepare( "WHERE p.post_date $op %s AND p.post_type = %s AND p.post_status = 'publish' $posts_in_ex_terms_sql", $current_post_date, $post->post_type), $in_same_term, $excluded_terms );
     1542        $where = apply_filters( "get_{$adjacent}_post_where", $wpdb->prepare( "WHERE ( p.post_date $op %s OR ( p.post_date = %s AND p.ID $op %d ) ) AND p.post_type = %s AND p.post_status = 'publish' $posts_in_ex_terms_sql", $current_post_date, $current_post_date, $post->ID, $post->post_type), $in_same_term, $excluded_terms );
    15431543
    15441544        /**
    15451545         * Filter the ORDER BY clause in the SQL for an adjacent post query.