From 6018669f89ba084f5d5d60b89fe7fcb649279aa7 Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Fri, 3 Oct 2008 03:12:42 +0000 Subject: [PATCH] Don't show avatar for pingbacks or trackbacks git-svn-id: https://develop.svn.wordpress.org/trunk@9075 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/pluggable.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/wp-includes/pluggable.php b/wp-includes/pluggable.php index d3d37be766..8a753a1dad 100644 --- a/wp-includes/pluggable.php +++ b/wp-includes/pluggable.php @@ -1471,6 +1471,9 @@ function get_avatar( $id_or_email, $size = '96', $default = '', $alt = 'Avatar' if ( $user ) $email = $user->user_email; } elseif ( is_object($id_or_email) ) { + if ( isset($id_or_email->comment_type) && '' != $id_or_email->comment_type ) + return false; // No avatar for pingbacks or trackbacks + if ( !empty($id_or_email->user_id) ) { $id = (int) $id_or_email->user_id; $user = get_userdata($id);