diff options
Diffstat (limited to 'src/AppBundle/Controller/NewDataController.php')
-rw-r--r-- | src/AppBundle/Controller/NewDataController.php | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/src/AppBundle/Controller/NewDataController.php b/src/AppBundle/Controller/NewDataController.php index b6ed181..f63a7fa 100644 --- a/src/AppBundle/Controller/NewDataController.php +++ b/src/AppBundle/Controller/NewDataController.php @@ -37,43 +37,8 @@ class NewDataController extends Controller $response = new Response($data); $response->headers->set('Content-Type', 'application/json'); - $this->sendEmail("Marcin"); - return $response; } - public function sendEmail($name) - { - $message = (new \Swift_Message('Hello Email')) - ->setFrom('***REMOVED***') - ->setTo('***REMOVED***@edu.easj.dk') - ->setBody( - $this->renderView( - // app/Resources/views/Emails/registration.html.twig - 'Emails/registration.html.twig', - array('name' => $name) - ), - 'text/html' - ) - /* - * If you also want to include a plaintext version of the message - ->addPart( - $this->renderView( - 'Emails/registration.txt.twig', - array('name' => $name) - ), - 'text/plain' - ) - */ - ; - - //$mailer->send($message); - - // or, you can also fetch the mailer service this way - $this->get('mailer')->send($message); - - return $this->render(...); - } - } |