Limit recent entries query to published posts. fixes #4786

git-svn-id: https://develop.svn.wordpress.org/trunk@5973 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Ryan Boren 2007-08-29 18:02:19 +00:00
parent 6fc09cfd3b
commit 0210464be1
1 changed files with 1 additions and 1 deletions

View File

@ -810,7 +810,7 @@ function wp_widget_recent_entries($args) {
else if ( $number > 15 )
$number = 15;
$r = new WP_Query("showposts=$number&what_to_show=posts&nopaging=0");
$r = new WP_Query("showposts=$number&what_to_show=posts&nopaging=0&post_status=publish");
if ($r->have_posts()) :
?>
<?php echo $before_widget; ?>