Skip to content

Commit

Permalink
Mailer final fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Aroucha Bros Pinto authored and Aroucha Bros Pinto committed Apr 30, 2020
1 parent 10d86c7 commit f5ed64c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
Binary file modified .DS_Store
Binary file not shown.
8 changes: 3 additions & 5 deletions src/Controller/ContactController.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,17 @@
use Symfony\Component\Form\Extension\Core\Type\TextType;
use Symfony\Component\Form\Extension\Core\Type\TextareaType;
use Symfony\Component\HttpFoundation\Request;
/*use Symfony\Component\Mailer\MailerInterface;
use Symfony\Component\Mailer\MailerInterface;
use Symfony\Bridge\Twig\Mime\TemplatedEmail;
use Symfony\Component\Mime\Email;
use Symfony\Component\Mime\Address;*/
use Symfony\Component\Mime\Address;

class ContactController extends AbstractController
{
/**
* @Route("/contact", name="contact", options={"sitemap" = {"priority" = 0.7 }})
*/
public function index(Request $request /*, MailerInterface $mailer*/)
public function index(Request $request , MailerInterface $mailer)
{
$contact = new Contact();

Expand Down Expand Up @@ -50,7 +50,6 @@ public function index(Request $request /*, MailerInterface $mailer*/)
$entityManager->persist($contact);
$entityManager->flush();

/*
$email = (new TemplatedEmail())
->from(new Address('[email protected]', 'Site da Casalit - '.$contact->getName()))
->to('[email protected]')
Expand All @@ -65,7 +64,6 @@ public function index(Request $request /*, MailerInterface $mailer*/)
]);

$mailer->send($email);
*/

$this->addFlash(
'notice',
Expand Down

0 comments on commit f5ed64c

Please sign in to comment.