Make WordPress Core


Ignore:
Timestamp:
08/20/2012 07:47:52 PM (12 years ago)
Author:
ryan
Message:

Introduce WP_Post class. Clean up ancestors handling. Props scribu, toppa. fixes #10381 see #21309

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/post-template.php

    r21333 r21559  
    10171017        if ( !empty($current_page) ) {
    10181018            $_current_page = get_page( $current_page );
    1019             _get_post_ancestors($_current_page);
    1020             if ( isset($_current_page->ancestors) && in_array($page->ID, (array) $_current_page->ancestors) )
     1019            if ( in_array( $page->ID, $_current_page->ancestors ) )
    10211020                $css_class[] = 'current_page_ancestor';
    10221021            if ( $page->ID == $current_page )
Note: See TracChangeset for help on using the changeset viewer.