mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-06-28 22:30:04 +00:00
Use the create_posts post type cap in more places. Remove the janky create_posts meta cap. see #16714.
git-svn-id: https://develop.svn.wordpress.org/trunk@22908 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -1060,14 +1060,6 @@ function map_meta_cap( $cap, $user_id ) {
|
||||
$caps[] = $post_type->cap->delete_private_posts;
|
||||
}
|
||||
break;
|
||||
// current_user_can( 'create_posts', $post_type )
|
||||
case 'create_posts':
|
||||
$post_type = isset( $args[0] ) ? $args[0] : 'post';
|
||||
$post_type_object = get_post_type_object( $post_type );
|
||||
|
||||
$caps[] = $post_type_object->cap->create_posts;
|
||||
|
||||
break;
|
||||
// edit_post breaks down to edit_posts, edit_published_posts, or
|
||||
// edit_others_posts
|
||||
case 'edit_post':
|
||||
|
||||
Reference in New Issue
Block a user