src/Event.php
protected function sendEmail(MailerInterface $mailer, $address)
    {
        $message = $mailer->compose();
        $message->setTextBody(file_get_contents($this->_output))
            ->setSubject($this->getEmailSubject())
            ->setTo($address);

        $message->send();
    }
protected function sendEmail(MailerInterface $mailer, $address)
    {
        $message = $mailer->compose();
        $message->setTextBody(file_get_contents($this->_output))
            ->setSubject($this->getEmailSubject())
            ->setTo($address);

        $message->send();
    }
protected function sendEmail ( MailerInterface $ mailer , $ address ) { $ message = $ mailer -> compose ( ) ; $ message -> setTextBody ( file_get_contents ( $ this -> _output ) ) -> setSubject ( $ this -> getEmailSubject ( ) ) -> setTo ( $ address ) ; $ message -> send ( ) ; }
Send email logic.

@param MailerInterface $mailer
@param array $address
Send email logic .