Compare commits
No commits in common. "689c3203e707a5cf10b8c9e1a172371b8d0fbb10" and "d3e6100d17b87af1252791977825ed0ed28b1f4b" have entirely different histories.
689c3203e7
...
d3e6100d17
@ -12,8 +12,6 @@ class SwiftMailer implements MailerInterface
|
||||
|
||||
protected $to;
|
||||
|
||||
protected $cc;
|
||||
|
||||
public function __construct(EmailConfiguration $configuration) {
|
||||
$this->emailConfiguration = $configuration;
|
||||
|
||||
@ -27,30 +25,20 @@ class SwiftMailer implements MailerInterface
|
||||
$swiftObj = ( new \Swift_Message($subject) )
|
||||
->setFrom( $this->from )
|
||||
->setTo( $this->to )
|
||||
->setCC($this->cc ?? [])
|
||||
->setBody( $message, $html ? 'text/html' : 'text/plain' );
|
||||
|
||||
return ( new \Swift_Mailer($this->transport) )->send($swiftObj);
|
||||
}
|
||||
|
||||
public function setFrom(/*stringable|array*/ $from) : MailerInterface
|
||||
public function setFrom($from) : MailerInterface
|
||||
{
|
||||
$this->from = $from;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function setTo(/*stringable|array*/ $to) : MailerInterface
|
||||
public function setTo($to) : MailerInterface
|
||||
{
|
||||
$this->to = $to;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function setCC(/*stringable|array*/ $cc) : MailerInterface
|
||||
{
|
||||
$this->cc = $cc;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user