Opened 11 years ago
Closed 11 years ago
#26944 closed enhancement (fixed)
Dashboard "At a glance" widget ignores get_avatar_comment_types filter
Reported by: | zodiac1978 | Owned by: | ocean90 |
---|---|---|---|
Milestone: | 3.9 | Priority: | normal |
Severity: | minor | Version: | 3.8 |
Component: | Comments | Keywords: | has-patch dev-feedback |
Focuses: | ui | Cc: |
Description
The "At a Glance" dashboard widget does not show gravatars for anything which is not a comment.
https://core.trac.wordpress.org/browser/trunk/src/wp-admin/includes/dashboard.php#L487
But there can be a new different comment_type
added:
https://core.trac.wordpress.org/browser/trunk/src/wp-includes/pluggable.php#L1696
Because get_avatar
has its own comment_type
check we can move the get_avatar
out of the if/else/endif. So we can add a new comment_type
with gravatars per get_avatar_comment_types
filter.
Attachments (1)
Change History (8)
#3
follow-up:
↓ 4
@
11 years ago
- Component changed from Administration to Comments
- Focuses ui added
- Keywords dev-feedback removed
- Milestone changed from Awaiting Review to 3.9
- Type changed from defect (bug) to enhancement
Looks good. But it's more an enhancement.
#4
in reply to:
↑ 3
@
11 years ago
Replying to ocean90:
Looks good. But it's more an enhancement.
I think it is a bug, because if you add gravatar comment_types per filter you should get avatars for this comment_type in all places. But the widget does not show them.
As an alternative the widget could use the same way as the get_avatar function in pluggable.php to check how to handle the comment (e.g. use the same filter to add comment_types, check for ID/email instead of just checking comment_type).
Moved get_avatar line from dashboard widget out of if-block