mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-04-04 04:34:31 +00:00
Dashboard: use the create_posts cap on the post type object when determining if the Quick Press widget can be displayed.
Props jim912, ocean90, chriscct7. Fixes #25681. git-svn-id: https://develop.svn.wordpress.org/trunk@35282 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -71,7 +71,7 @@ case 'post-quickdraft-save':
|
||||
if ( ! wp_verify_nonce( $nonce, 'add-post' ) )
|
||||
$error_msg = __( 'Unable to submit this form, please refresh and try again.' );
|
||||
|
||||
if ( ! current_user_can( 'edit_posts' ) ) {
|
||||
if ( ! current_user_can( get_post_type_object( 'post' )->cap->create_posts ) ) {
|
||||
exit;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user