fd13f5f8e9
This PR was squashed before being merged into the 4.4 branch.
Discussion
----------
[Mailer] Fix reply-to functionality in the SendgridApiTransport
| Q | A
| ------------- | ---
| Branch? | 4.4
| Bug fix? | yes
| New feature? | no
| Deprecations? | no
| Tickets |
| License | MIT
| Doc PR |
When sending a message using the `SendgridApiTransport`, the reply-to address was being ignored. In other transports, the reply to can be set using headers, but SendGrid requires that certain fields be added explicitly to the API payload. This is already handled for From, To, Cc, Bcc, and Subject, but was not handled for Reply-To. This change extracts the reply to address from the `Email` object and adds it to the payload.
Note that the `Email` object allows for multiple Reply-To addresses, but SendGrid only supports a single one, so I am just using the first element of the array.
I also fixed a link in a comment to SendGrid's documentation explaining the reserved headers that are not allowed.
Commits
-------
|
||
---|---|---|
.. | ||
Bridge | ||
DataCollector | ||
Event | ||
EventListener | ||
Exception | ||
Messenger | ||
Test | ||
Tests | ||
Transport | ||
.gitattributes | ||
.gitignore | ||
CHANGELOG.md | ||
composer.json | ||
DelayedEnvelope.php | ||
Envelope.php | ||
LICENSE | ||
Mailer.php | ||
MailerInterface.php | ||
phpunit.xml.dist | ||
README.md | ||
SentMessage.php | ||
Transport.php |
Mailer Component
The Mailer component helps sending emails.