Fix typos in [13729]. edit_type_cap is a primitive cap, not meta. @todo: audit ptype cap calls.

git-svn-id: https://develop.svn.wordpress.org/trunk@13890 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin 2010-03-30 13:16:28 +00:00
parent 4746be453f
commit 8d38a2f78e
1 changed files with 2 additions and 2 deletions

View File

@ -241,7 +241,7 @@ function bulk_edit_posts( $post_data = null ) {
else
$ptype = get_post_type_object('post');
if ( !current_user_can( $ptype->edit_type_cap, $post_ID ) ) {
if ( !current_user_can( $ptype->edit_type_cap ) ) {
if ( 'page' == $ptype->name )
wp_die( __('You are not allowed to edit pages.'));
else
@ -492,7 +492,7 @@ function wp_write_post() {
else
$ptype = get_post_type_object('post');
if ( !current_user_can( $ptype->edit_type_cap, $post_ID ) ) {
if ( !current_user_can( $ptype->edit_type_cap ) ) {
if ( 'page' == $ptype->name )
return new WP_Error( 'edit_pages', __( 'You are not allowed to create pages on this blog.' ) );
else