Add filter for email recipients in wp_notify_moderator()
|Reported by:||lexhair||Owned by:||nacin|
As administrator, I would like more control over email notifications when comments are marked for moderation without having to overwrite the pluggable function wp_notify_moderator.
The function wp_notify_moderator sends emails to post authors (when they have sufficient roles) and the admin by hard coding the $email_to array. I'd like to see the $email_to array sent to a filter with $comment before wp_mail() is called. That would allow me to write a theme function to manipulate the $email_to array to add or delete recipients.
My workaround was to write a site specific plugin that overwrote wp_notify_moderator() to manipulate the $email_to array.
Change History (9)
comment:4 chipbennett — 16 months ago
- Component changed from General to Comments
- Keywords has-patch needs-testing added
- Owner set to nacin
- Resolution set to fixed
- Status changed from new to closed