channels; } public function addChannel(string $channel): void { if (!in_array($channel, $this->channels)) { $this->channels[] = $channel; } } public function toArray(): array { return [ 'message' => $this->getMessage(), 'subject' => $this->getSubject(), ]; } }