Don't show unapproved comments in comments widget. props jshreve, fixes #10615.
git-svn-id: https://develop.svn.wordpress.org/trunk@14679 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
60c2623599
commit
e6fcc1df7c
@ -644,7 +644,7 @@ class WP_Widget_Recent_Comments extends WP_Widget {
|
|||||||
else if ( $number < 1 )
|
else if ( $number < 1 )
|
||||||
$number = 1;
|
$number = 1;
|
||||||
|
|
||||||
$comments = get_comments(array('number' => $number));
|
$comments = get_comments( array( 'number' => $number, 'status' => 'approve' ) );
|
||||||
$output .= $before_widget;
|
$output .= $before_widget;
|
||||||
if ( $title )
|
if ( $title )
|
||||||
$output .= $before_title . $title . $after_title;
|
$output .= $before_title . $title . $after_title;
|
||||||
|
Loading…
Reference in New Issue
Block a user