Permalink
Browse files

Don't show edit link for comments when the user cannot edit them, pro…

…ps filosofo, fixes #10520 for 2.8

git-svn-id: http://svn.automattic.com/wordpress/branches/2.8@11751 1a063a9b-81f0-0310-95a4-ce76da25c4cd
  • Loading branch information...
1 parent 9681a52 commit f1f76a4e4c47bd2fdd9864a0f3efccdb782ac78a azaozz committed Jul 30, 2009
Showing with 1 addition and 2 deletions.
  1. +1 −2 wp-includes/link-template.php
@@ -768,8 +768,7 @@ function get_edit_comment_link( $comment_id = 0 ) {
function edit_comment_link( $link = 'Edit This', $before = '', $after = '' ) {
global $comment, $post;
- if ( $post->post_type == 'attachment' ) {
- } elseif ( $post->post_type == 'page' ) {
+ if ( $post->post_type == 'page' ) {
if ( !current_user_can( 'edit_page', $post->ID ) )
return;
} else {

0 comments on commit f1f76a4

Please sign in to comment.