Skip to content

rename SmtpEnvelope to Envelope #12321

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 16, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions components/mailer.rst
Original file line number Diff line number Diff line change
Expand Up @@ -137,10 +137,10 @@ If you want to send emails asynchronously, install the :doc:`Messenger component

Then, instantiate and pass a ``MessageBus`` as a second argument to ``Mailer``::

use Symfony\Component\Mailer\Envelope;
use Symfony\Component\Mailer\Mailer;
use Symfony\Component\Mailer\Messenger\MessageHandler;
use Symfony\Component\Mailer\Messenger\SendEmailMessage;
use Symfony\Component\Mailer\SmtpEnvelope;
use Symfony\Component\Mailer\Transport;
use Symfony\Component\Messenger\Handler\HandlersLocator;
use Symfony\Component\Messenger\MessageBus;
Expand All @@ -162,7 +162,7 @@ Then, instantiate and pass a ``MessageBus`` as a second argument to ``Mailer``::
$mailer->send($email);

// you can pass an optional Envelope
$mailer->send($email, new SmtpEnvelope(
$mailer->send($email, new Envelope(
new Address('sender@example.com'),
[
new Address('recipient@example.com'),
Expand Down