Make WordPress Core

Changeset 3602


Ignore:
Timestamp:
03/03/2006 02:18:55 AM (20 years ago)
Author:
ryan
Message:

Make sure posts array is not empty before checking preview state. #2498

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.0/wp-includes/classes.php

    r3551 r3602  
    655655
    656656        // Check post status to determine if post should be displayed.
    657         if ($this->is_single) {
     657        if ( !empty($this->posts) && $this->is_single ) {
    658658            $status = get_post_status($this->posts[0]);
    659659            if ( ('publish' != $status) && ('static' != $status) ) {
Note: See TracChangeset for help on using the changeset viewer.