Make WordPress Core


Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/3.1/wp-admin/admin-ajax.php

    r17354 r18018  
    397397                die('1');
    398398
    399         if ( !current_user_can( 'edit_post', $meta->post_id ) )
     399        if ( !current_user_can( 'edit_post', $meta->post_id ) || is_protected_meta( $meta->meta_key ) )
    400400                die('-1');
    401401        if ( delete_meta( $meta->meta_id ) )
     
    856856                if ( !current_user_can( 'edit_post', $meta->post_id ) )
    857857                        die('-1');
     858                if ( is_protected_meta( $meta->meta_key ) )
     859                        die('-1');
    858860                if ( $meta->meta_value != stripslashes($value) || $meta->meta_key != stripslashes($key) ) {
    859861                        if ( !$u = update_meta( $mid, $key, $value ) )
Note: See TracChangeset for help on using the changeset viewer.