diff --git a/src/Utils/Utils.php b/src/Utils/Utils.php new file mode 100644 index 0000000..d15f4b5 --- /dev/null +++ b/src/Utils/Utils.php @@ -0,0 +1,35 @@ +from($from) + ->to($to) + ->subject($subject) + ->replyTo($from) + ->html($content); + + try { + $mailer->send($mail); + } catch (TransportExceptionInterface $e) { + die($e->getMessage()); + // some error prevented the email sending; display an + // error message or try to resend the message + } + } +}