Changeset 18018 for branches/3.1/wp-admin/includes/post.php
- Timestamp:
- 05/24/2011 03:53:22 PM (14 years ago)
- Location:
- branches/3.1
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3.1
-
branches/3.1/wp-admin/includes/post.php
r17458 r18018 139 139 $post = get_post( $post_ID ); 140 140 $post_data['post_type'] = $post->post_type; 141 $post_data['post_mime_type'] = $post->post_mime_type; 141 142 142 143 $ptype = get_post_type_object($post_data['post_type']); … … 200 201 if ( $meta->post_id != $post_ID ) 201 202 continue; 203 if ( is_protected_meta( $key ) ) 204 continue; 202 205 update_meta( $key, $value['key'], $value['value'] ); 203 206 } … … 209 212 continue; 210 213 if ( $meta->post_id != $post_ID ) 214 continue; 215 if ( is_protected_meta( $key ) ) 211 216 continue; 212 217 delete_meta( $key ); … … 528 533 } 529 534 535 $_POST['post_mime_type'] = ''; 536 530 537 // Check for autosave collisions 531 538 // Does this need to be updated? ~ Mark … … 633 640 $post_ID = (int) $post_ID; 634 641 635 $protected = array( '_wp_attached_file', '_wp_attachment_metadata', '_wp_old_slug', '_wp_page_template' );636 637 642 $metakeyselect = isset($_POST['metakeyselect']) ? stripslashes( trim( $_POST['metakeyselect'] ) ) : ''; 638 643 $metakeyinput = isset($_POST['metakeyinput']) ? stripslashes( trim( $_POST['metakeyinput'] ) ) : ''; … … 651 656 $metakey = $metakeyinput; // default 652 657 653 if ( i n_array($metakey, $protected) )658 if ( is_protected_meta( $metakey ) ) 654 659 return false; 655 660 … … 757 762 global $wpdb; 758 763 759 $protected = array( '_wp_attached_file', '_wp_attachment_metadata', '_wp_old_slug', '_wp_page_template' );760 761 764 $meta_key = stripslashes($meta_key); 762 765 763 if ( i n_array($meta_key, $protected) )766 if ( is_protected_meta( $meta_key ) ) 764 767 return false; 765 768
Note: See TracChangeset
for help on using the changeset viewer.