WordPress.org

Make WordPress Core

Changeset 8555


Ignore:
Timestamp:
08/05/08 21:07:59 (7 years ago)
Author:
ryan
Message:

Use get_term_by() instead of is_term() to query slug. see #6593

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/query.php

    r8546 r8555  
    11271127            $include_tags = "'" . implode("', '", $q['tag_slug__in']) . "'"; 
    11281128            $whichcat .= " AND $wpdb->terms.slug IN ($include_tags) "; 
    1129             $reqtag = is_term( $q['tag_slug__in'][0], 'post_tag' ); 
     1129            $reqtag = get_term_by( 'slug', $q['tag_slug__in'][0], 'post_tag' ); 
    11301130            if ( !empty($reqtag) ) 
    1131                 $q['tag_id'] = $reqtag['term_id']; 
     1131                $q['tag_id'] = $reqtag->term_id; 
    11321132        } 
    11331133 
Note: See TracChangeset for help on using the changeset viewer.