Feature Description
While debugging another issue, I found that the buildHeaders method is not being used in all of the places where emails are being sent within the plugin. Realistically, this means that the sender name will be inconsistent across all emails sent from the plugin, although this is a low-priority fix, it's worth looking at when we get the chance.
Do not alter or remove anything below. The following sections will be managed by moderators only.
Acceptance Criteria
- Monthly/weekly report emails and invitation emails use the same header-building method as error notification emails
- No email send path passes an empty array for headers
Implementation Brief
Backend
Test Coverage
QA Brief
- From the Site Kit dashboard, click your user avatar, choose "Manage email reports", select "Weekly", then click "Subscribe", and confirm the subscription email's From header reads
Site Kit <admin-email> matching Settings → General.
- In the same panel, scroll to "Invite others to subscribe", click "Send invite" on an eligible non-subscribed user, and confirm the invitation email's From header reads the same
Site Kit <admin-email>.
Changelog entry
- Ensure email headers always include the correct "From" header.
Feature Description
While debugging another issue, I found that the buildHeaders method is not being used in all of the places where emails are being sent within the plugin. Realistically, this means that the sender name will be inconsistent across all emails sent from the plugin, although this is a low-priority fix, it's worth looking at when we get the chance.
Do not alter or remove anything below. The following sections will be managed by moderators only.
Acceptance Criteria
Implementation Brief
Backend
Update file
includes/Core/Email_Reporting/Email_Report_Sender.phparray()with$this->email_sender->build_headers()in thesend()call at line 88Update file
includes/Core/Email_Reporting/REST_Email_Reporting_Controller.phparray()with$this->email_sender->build_headers()in the invitation send call at line 405Test Coverage
tests/phpunit/integration/Core/Email_Reporting/Worker_TaskTest.phpsend()parameter assertions fromarray()to$this->isType( 'array' )QA Brief
Site Kit <admin-email>matchingSettings → General.Site Kit <admin-email>.Changelog entry