s/$blog/$blog_id/ as an argument in wp_dropdown_users(), for consistency, see #11086

git-svn-id: http://svn.automattic.com/wordpress/trunk@13123 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
nacin 2010-02-13 20:17:15 +00:00
parent 426a33b134
commit 4caf701cdf
1 changed files with 4 additions and 4 deletions

View File

@ -507,7 +507,7 @@ function setup_userdata($for_user_id = '') {
* <li>selected - Which User ID is selected.</li>
* <li>name - Default is 'user'. Name attribute of select element.</li>
* <li>class - Class attribute of select element.</li>
* <li>blog - ID of blog (Multisite only). Defaults to ID of current blog.</li>
* <li>blog_id - ID of blog (Multisite only). Defaults to ID of current blog.</li>
* </ol>
*
* @since 2.3.0
@ -517,13 +517,13 @@ function setup_userdata($for_user_id = '') {
* @return string|null Null on display. String of HTML content on retrieve.
*/
function wp_dropdown_users( $args = '' ) {
global $wpdb, $blog_id;
global $wpdb;
$defaults = array(
'show_option_all' => '', 'show_option_none' => '',
'orderby' => 'display_name', 'order' => 'ASC',
'include' => '', 'exclude' => '', 'multi' => 0,
'show' => 'display_name', 'echo' => 1,
'selected' => 0, 'name' => 'user', 'class' => '', 'blog' => $blog_id,
'selected' => 0, 'name' => 'user', 'class' => '', 'blog_id' => $GLOBALS['blog_id'],
);
$defaults['selected'] = is_author() ? get_query_var( 'author' ) : 0;
@ -531,7 +531,7 @@ function wp_dropdown_users( $args = '' ) {
$r = wp_parse_args( $args, $defaults );
extract( $r, EXTR_SKIP );
$blog_prefix = $wpdb->get_blog_prefix( $blog );
$blog_prefix = $wpdb->get_blog_prefix( $blog_id );
$query = "SELECT {$wpdb->users}.* FROM $wpdb->users, $wpdb->usermeta WHERE {$wpdb->users}.ID = {$wpdb->usermeta}.user_id AND meta_key = '{$blog_prefix}capabilities'";
$query_where = array();