Make WordPress Core


Ignore:
Timestamp:
05/16/2008 03:57:09 AM (18 years ago)
Author:
matt
Message:

get_queried_object should not return an array of terms, and wp_title should check is_tax. Hat tip: andy

File:
1 edited

Legend:

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

    r7906 r7941  
    16111611            $slug = $this->get('term');
    16121612            $term = &get_terms($tax, array('slug'=>$slug));
    1613             if ( is_wp_error($term) )
     1613            if ( is_wp_error($term) || empty($term) )
    16141614                return $term;
     1615            $term = $term[0];
    16151616            $this->queried_object = $term;
    16161617            $this->queried_object_id = $term->term_id;
Note: See TracChangeset for help on using the changeset viewer.