diff options
Diffstat (limited to 'wp-includes/user.php')
| -rw-r--r-- | wp-includes/user.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/wp-includes/user.php b/wp-includes/user.php index 14de35a..ca4006b 100644 --- a/wp-includes/user.php +++ b/wp-includes/user.php @@ -10,7 +10,7 @@ function get_profile($field, $user = false) { function get_usernumposts($userid) { global $wpdb; $userid = (int) $userid; - return $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->posts WHERE post_author = '$userid' AND post_type = 'post' AND post_status = 'publish'"); + return $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->posts WHERE post_author = '$userid' AND post_type = 'post' AND " . get_private_posts_cap_sql('post')); } // TODO: xmlrpc only. Maybe move to xmlrpc.php. |
