diff --git a/src/Illuminate/Mail/Mailable.php b/src/Illuminate/Mail/Mailable.php index 0b72d25dc29..9e1f8eed570 100644 --- a/src/Illuminate/Mail/Mailable.php +++ b/src/Illuminate/Mail/Mailable.php @@ -328,6 +328,18 @@ public function from($address, $name = null) return $this->setAddress($address, $name, 'from'); } + /** + * Determine if the given recipient is set on the mailable. + * + * @param object|array|string $address + * @param string|null $name + * @return bool + */ + public function hasFrom($address, $name = null) + { + return $this->hasRecipient($address, $name, 'from'); + } + /** * Set the recipients of the message. *