Changeset 2777 for sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/admin/list-table/class-committers.php
- Timestamp:
- 03/22/2016 06:21:26 AM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/admin/list-table/class-committers.php
r2764 r2777 33 33 */ 34 34 public function ajax_user_can() { 35 return current_user_can( ' manage_committers' );35 return current_user_can( 'plugin_remove_committer' ); 36 36 } 37 37 … … 150 150 151 151 // Check if the committer for this row is removable. 152 if ( current_user_can( 'list_users' ) ) {153 $post_id = get_post()->ID;152 $post_id = get_post()->ID; 153 if ( current_user_can( 'plugin_remove_committer', $post_id ) && $user_object->ID != get_current_user_id() ) { 154 154 $actions['delete'] = "<a class='submitremove' data-wp-lists='delete:the-committer-list:committer-{$user_object->ID}:faafaa:post_id={$post_id}' href='" . wp_nonce_url( 'users.php?action=remove&committer=' . $user_object->ID, "remove-committer-{$user_object->ID}" ) . "'>" . __( 'Remove', 'wporg-plugins' ) . "</a>"; 155 155 }
Note: See TracChangeset
for help on using the changeset viewer.