Remove single-argument calls to wpdb:prepare(), which are invalid as nothing is being prepared. see #22262.
git-svn-id: http://core.svn.wordpress.org/trunk@22428 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
2aa561013b
commit
3a86c87c31
|
@ -1919,6 +1919,6 @@ function wp_update_network_counts() {
|
|||
$count = $wpdb->get_var( $wpdb->prepare("SELECT COUNT(blog_id) as c FROM $wpdb->blogs WHERE site_id = %d AND spam = '0' AND deleted = '0' and archived = '0'", $wpdb->siteid) );
|
||||
update_site_option( 'blog_count', $count );
|
||||
|
||||
$count = $wpdb->get_var( $wpdb->prepare("SELECT COUNT(ID) as c FROM $wpdb->users WHERE spam = '0' AND deleted = '0'") );
|
||||
$count = $wpdb->get_var( "SELECT COUNT(ID) as c FROM $wpdb->users WHERE spam = '0' AND deleted = '0'" );
|
||||
update_site_option( 'user_count', $count );
|
||||
}
|
||||
|
|
|
@ -2406,7 +2406,7 @@ class WP_Query {
|
|||
if ( 'any' == $post_type ) {
|
||||
$in_search_post_types = get_post_types( array('exclude_from_search' => false) );
|
||||
if ( ! empty( $in_search_post_types ) )
|
||||
$where .= $wpdb->prepare(" AND $wpdb->posts.post_type IN ('" . join("', '", $in_search_post_types ) . "')");
|
||||
$where .= " AND $wpdb->posts.post_type IN ('" . join("', '", $in_search_post_types ) . "')";
|
||||
} elseif ( !empty( $post_type ) && is_array( $post_type ) ) {
|
||||
$where .= " AND $wpdb->posts.post_type IN ('" . join("', '", $post_type) . "')";
|
||||
} elseif ( ! empty( $post_type ) ) {
|
||||
|
|
Loading…
Reference in New Issue