Ticket #24054: 24054.diff
File 24054.diff, 1.4 KB (added by , 9 years ago) |
---|
-
src/wp-includes/comment-template.php
420 420 // Get the comment type (comment, trackback), 421 421 $classes[] = ( empty( $comment->comment_type ) ) ? 'comment' : $comment->comment_type; 422 422 423 // If the comment author has an id (registered) , then print the log in name424 if ( $comment->user_id > 0 && $user = get_userdata( $comment->user_id) ) {425 // For all registered users , 'byuser'423 // If the comment author has an id (registered) 424 if ( $comment->user_id > 0 && $user = get_userdata( $comment->user_id ) ) { 425 // For all registered users 426 426 $classes[] = 'byuser'; 427 $classes[] = 'comment-author-' . sanitize_html_class($user->user_nicename, $comment->user_id); 427 $classes[] = 'comment-author-' . sanitize_html_class( $user->user_nicename, $comment->user_id ); 428 429 // For all members of this blog (useful for multi-site) 430 if ( is_user_member_of_blog( $comment->user_id ) ) { 431 $classes[] = 'comment-author-is-site-member'; 432 } 433 428 434 // For comment authors who are the author of the post 429 435 if ( $post = get_post($post_id) ) { 430 if ( $comment->user_id === $post->post_author ) 436 if ( $comment->user_id === $post->post_author ) { 431 437 $classes[] = 'bypostauthor'; 438 } 432 439 } 433 440 } 434 441