Changeset 9701 for trunk/wp-admin/includes/post.php
- Timestamp:
- 11/14/2008 11:34:18 PM (18 years ago)
- File:
-
- 1 edited
-
trunk/wp-admin/includes/post.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-admin/includes/post.php
r9699 r9701 76 76 // Posts 'submitted for approval' present are submitted to $_POST the same as if they were being published. 77 77 // Change status from 'publish' to 'pending' if user lacks permissions to publish or to resave published posts. 78 if ( isset($post_data['post_status']) && ('publish' == $post_data['post_status'] && !current_user_can( 'publish_posts' )) ) 79 if ( $previous_status != 'publish' OR !current_user_can( 'edit_published_pages') ) 78 if ( 'page' == $post_data['post_type'] ) { 79 $publish_cap = 'publish_pages'; 80 $edit_cap = 'edit_published_pages'; 81 } else { 82 $publish_cap = 'publish_posts'; 83 $edit_cap = 'edit_published_posts'; 84 } 85 if ( isset($post_data['post_status']) && ('publish' == $post_data['post_status'] && !current_user_can( $publish_cap )) ) 86 if ( $previous_status != 'publish' || !current_user_can( $edit_cap ) ) 80 87 $post_data['post_status'] = 'pending'; 81 88
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)