Ticket #17582: found_users_query.17582.diff
File found_users_query.17582.diff, 769 bytes (added by , 14 years ago) |
---|
-
wp-includes/user.php
545 545 $this->results = $wpdb->get_col("SELECT $this->query_fields $this->query_from $this->query_where $this->query_orderby $this->query_limit"); 546 546 } 547 547 548 if ( $this->query_vars['count_total'] ) 549 $this->total_users = $wpdb->get_var("SELECT COUNT(*) $this->query_from $this->query_where"); 548 if ( $this->query_vars['count_total'] ) { 549 $found_users_query = apply_filters( 'found_users_query', "SELECT COUNT(*) $this->query_from $this->query_where", $this ); 550 $this->total_users = $wpdb->get_var( $found_users_query ); 551 } 550 552 551 553 if ( !$this->results ) 552 554 return;