WordPress.org

Make WordPress Core

Changeset 6333


Ignore:
Timestamp:
11/12/2007 07:58:09 PM (12 years ago)
Author:
ryan
Message:

Check publish_posts not edit_published_posts when setting pending status. Props jeremyclarke. fixes #5329

File:
1 edited

Legend:

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

    r6287 r6333  
    6464
    6565    if ( 'page' == $_POST['post_type'] ) {
    66         if ('publish' == $_POST['post_status'] && !current_user_can( 'edit_published_pages' ))
     66        if ('publish' == $_POST['post_status'] && !current_user_can( 'publish_pages' ))
    6767            $_POST['post_status'] = 'pending';
    6868    } else {
    69         if ('publish' == $_POST['post_status'] && !current_user_can( 'edit_published_posts' ))
     69        if ('publish' == $_POST['post_status'] && !current_user_can( 'publish_posts' ))
    7070            $_POST['post_status'] = 'pending';
    7171    }
Note: See TracChangeset for help on using the changeset viewer.