renderedSubject, from: $this->address($this->mailConfig['from_email'] ?? null, $this->mailConfig['from_name'] ?? null), replyTo: array_filter([$this->address($this->mailConfig['reply_to'] ?? null, $this->mailConfig['reply_to_name'] ?? null)]), cc: $this->mailConfig['cc'] ?? [], bcc: $this->mailConfig['bcc'] ?? [], ); } public function content(): Content { return new Content(htmlString: $this->renderedHtml); } private function address(?string $email, ?string $name): ?Address { return $email ? new Address($email, $name) : null; } }