WordPress.org

Make WordPress Core

Changeset 37803


Ignore:
Timestamp:
06/21/2016 02:47:24 PM (5 years ago)
Author:
rachelbaker
Message:

Revisions: Change the capability needed to view revision diffs to edit_post.

Merge of [37779] to the 3.9 branch.

Location:
branches/3.9/src/wp-admin
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/3.9/src/wp-admin/includes/ajax-actions.php

    r34155 r37803  
    21672167        wp_send_json_error();
    21682168
    2169     if ( ! current_user_can( 'read_post', $post->ID ) )
     2169    if ( ! current_user_can( 'edit_post', $post->ID ) )
    21702170        wp_send_json_error();
    21712171
  • branches/3.9/src/wp-admin/revision.php

    r27469 r37803  
    6464        break;
    6565
    66     if ( ! current_user_can( 'read_post', $revision->ID ) || ! current_user_can( 'read_post', $post->ID ) )
     66    if ( ! current_user_can( 'read_post', $revision->ID ) || ! current_user_can( 'edit_post', $revision->post_parent ) )
    6767        break;
    6868
Note: See TracChangeset for help on using the changeset viewer.