Make WordPress Core

Changeset 24336


Ignore:
Timestamp:
05/23/2013 06:16:24 PM (11 years ago)
Author:
ryan
Message:

Use the global post rather than the global post ID. They don't always match, and the global post is more canonical.

see #24330

File:
1 edited

Legend:

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

    r24301 r24336  
    194194    // Avoid parsing again if the post is the same one parsed by setup_postdata().
    195195    // The extract() will set up $pages and $multipage.
    196     if ( $post->ID != $GLOBALS['id'] )
     196    if ( $post->ID != get_post()->ID )
    197197        extract( wp_parse_post_content( $post, false ) );
    198198    else
Note: See TracChangeset for help on using the changeset viewer.