Make WordPress Core


Ignore:
Timestamp:
04/20/2011 06:02:41 PM (13 years ago)
Author:
ryan
Message:

Allow retrieving comments by post type, status, author, author, name, or parent. Fetch only published posts for recent comments widget. Props filosofo. fixes #16506 #12904

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/default-widgets.php

    r17655 r17667  
    641641            $number = 5;
    642642
    643         $comments = get_comments( array( 'number' => $number, 'status' => 'approve' ) );
     643        $comments = get_comments( array( 'number' => $number, 'status' => 'approve', 'post_status' => 'publish' ) );
    644644        $output .= $before_widget;
    645645        if ( $title )
Note: See TracChangeset for help on using the changeset viewer.