From 69f5922799c7900e98fd35152e7e2128dda1a8f9 Mon Sep 17 00:00:00 2001 From: nacin Date: Sat, 3 Apr 2010 04:38:20 +0000 Subject: [PATCH] Use correct cap in get_editable_user_ids(). edit_cap is the meta cap (edit_post) and needs a post id passed, edit_type_cap is the primitive edit_posts cap. git-svn-id: http://svn.automattic.com/wordpress/trunk@13955 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/includes/user.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-admin/includes/user.php b/wp-admin/includes/user.php index 24dd93c703..6a4478c3ae 100644 --- a/wp-admin/includes/user.php +++ b/wp-admin/includes/user.php @@ -250,7 +250,7 @@ function get_editable_user_ids( $user_id, $exclude_zeros = true, $post_type = 'p $post_type_obj = get_post_type_object($post_type); if ( ! $user->has_cap($post_type_obj->edit_others_cap) ) { - if ( $user->has_cap($post_type_obj->edit_cap) || $exclude_zeros == false ) + if ( $user->has_cap($post_type_obj->edit_type_cap) || ! $exclude_zeros ) return array($user->id); else return array();