use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\Mailer\Exception\TransportExceptionInterface;
use Symfony\Component\Mailer\MailerInterface;
-use Symfony\Component\Mime\NamedAddress;
+use Symfony\Component\Mime\Address;
use Symfony\Component\Routing\Generator\UrlGeneratorInterface;
use Symfony\Component\Routing\RouterInterface;
use Symfony\Component\Security\Core\Encoder\UserPasswordEncoderInterface;
//Create message
$message = (new TemplatedEmail())
//Set sender
- ->from(new NamedAddress($this->config['contact']['mail'], $this->config['contact']['name']))
+ ->from(new Address($this->config['contact']['mail'], $this->config['contact']['name']))
//Set recipient
//XXX: remove the debug set in vendor/symfony/mime/Address.php +46
- ->to(new NamedAddress($mail['context']['recipient_mail'], $mail['context']['recipient_name']))
+ ->to(new Address($mail['context']['recipient_mail'], $mail['context']['recipient_name']))
//Set subject
->subject($mail['subject'])
//Create message
$message = (new TemplatedEmail())
//Set sender
- ->from(new NamedAddress($this->config['contact']['mail'], $this->config['contact']['name']))
+ ->from(new Address($this->config['contact']['mail'], $this->config['contact']['name']))
//Set recipient
//XXX: remove the debug set in vendor/symfony/mime/Address.php +46
- ->to(new NamedAddress($mail['context']['recipient_mail'], $mail['context']['recipient_name']))
+ ->to(new Address($mail['context']['recipient_mail'], $mail['context']['recipient_name']))
//Set subject
->subject($mail['subject'])
//Create message
$message = (new TemplatedEmail())
//Set sender
- ->from(new NamedAddress($this->config['contact']['mail'], $this->config['contact']['name']))
+ ->from(new Address($this->config['contact']['mail'], $this->config['contact']['name']))
//Set recipient
//XXX: remove the debug set in vendor/symfony/mime/Address.php +46
- ->to(new NamedAddress($mail['context']['recipient_mail'], $mail['context']['recipient_name']))
+ ->to(new Address($mail['context']['recipient_mail'], $mail['context']['recipient_name']))
//Set subject
->subject($mail['subject'])