WordPress.org

Make WordPress Core

Changeset 13890


Ignore:
Timestamp:
03/30/10 13:16:28 (4 years ago)
Author:
nacin
Message:

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

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/post.php

    r13865 r13890  
    242242        $ptype = get_post_type_object('post'); 
    243243 
    244     if ( !current_user_can( $ptype->edit_type_cap, $post_ID ) ) { 
     244    if ( !current_user_can( $ptype->edit_type_cap ) ) { 
    245245        if ( 'page' == $ptype->name ) 
    246246            wp_die( __('You are not allowed to edit pages.')); 
     
    493493        $ptype = get_post_type_object('post'); 
    494494 
    495     if ( !current_user_can( $ptype->edit_type_cap, $post_ID ) ) { 
     495    if ( !current_user_can( $ptype->edit_type_cap ) ) { 
    496496        if ( 'page' == $ptype->name ) 
    497497            return new WP_Error( 'edit_pages', __( 'You are not allowed to create pages on this blog.' ) ); 
Note: See TracChangeset for help on using the changeset viewer.