Dropdownlijst in post of page laat niet alle gebruikers zien

Een bug; gelukkig schreef iemand deze code, die direct werkte!
http://wordpress.stackexchange.com/questions/91862/users-with-custom-roles-not-showing-in-post-author-select-box

[code] // Filter to fix the Post Author Dropdown
function author_override( $output ) {
global $post, $user_ID;

// return if this isn’t the theme author override dropdown
if (!preg_match(‘/post_author_override/’, $output)) return $output;

// return if we’ve already replaced the list (end recursion)
if (preg_match (‘/post_author_override_replaced/’, $output)) return $output;

// replacement call to wp_dropdown_users
$output = wp_dropdown_users(array(
‘echo’ => 0,
‘name’ => ‘post_author_override_replaced’,
‘selected’ => empty($post->ID) ? $user_ID : $post->post_author,
‘include_selected’ => true
));

// put the original name back
$output = preg_replace(‘/post_author_override_replaced/’, ‘post_author_override’, $output);

return $output;
}
add_filter(‘wp_dropdown_users’, ‘author_override’);
[/code]