Ticket #12104: 12104.diff
File 12104.diff, 1.5 KB (added by , 12 years ago) |
---|
-
wp-admin/edit-comments.php
8 8 9 9 /** WordPress Administration Bootstrap */ 10 10 require_once('./admin.php'); 11 if ( ! current_user_can('edit_posts') )11 if ( ! current_user_can( 'edit_posts' ) && ! current_user_can( 'moderate_comments' ) ) 12 12 wp_die(__('Cheatin’ uh?')); 13 13 14 14 $wp_list_table = _get_list_table('WP_Comments_List_Table'); -
wp-admin/menu.php
80 80 81 81 $awaiting_mod = wp_count_comments(); 82 82 $awaiting_mod = $awaiting_mod->moderated; 83 $menu[25] = array( sprintf( __('Comments %s'), "<span class='awaiting-mod count-$awaiting_mod'><span class='pending-count'>" . number_format_i18n($awaiting_mod) . "</span></span>" ), 'edit_posts', 'edit-comments.php', '', 'menu-top menu-icon-comments', 'menu-comments', 'div' ); 84 unset($awaiting_mod); 83 $cap = current_user_can( 'moderate_comments' ) ? 'moderate_comments' : 'edit_posts'; 84 $menu[25] = array( sprintf( __('Comments %s'), "<span class='awaiting-mod count-$awaiting_mod'><span class='pending-count'>" . number_format_i18n($awaiting_mod) . "</span></span>" ), $cap, 'edit-comments.php', '', 'menu-top menu-icon-comments', 'menu-comments', 'div' ); 85 unset($awaiting_mod, $cap); 85 86 86 87 $submenu[ 'edit-comments.php' ][0] = array( __('All Comments'), 'edit_posts', 'edit-comments.php' ); 87 88