mirror of
https://github.com/Seldaek/monolog.git
synced 2025-08-10 07:06:40 +02:00
Return self from NativeMailerHandler::addHeader().
NativeMailerHandler::setContentType() and NativeMailerHandler::setEncoding() both return the NativeMailerHandler object, allowing a fluent coding style. This fix adds the same behaviour to NativeMailerHandler::addHeader() for so that all public non-inherited methods behave this way for consistency.
This commit is contained in:
@@ -78,7 +78,7 @@ class NativeMailerHandler extends MailHandler
|
|||||||
* Add headers to the message
|
* Add headers to the message
|
||||||
*
|
*
|
||||||
* @param string|array $headers Custom added headers
|
* @param string|array $headers Custom added headers
|
||||||
* @return null
|
* @return self
|
||||||
*/
|
*/
|
||||||
public function addHeader($headers)
|
public function addHeader($headers)
|
||||||
{
|
{
|
||||||
@@ -88,6 +88,8 @@ class NativeMailerHandler extends MailHandler
|
|||||||
}
|
}
|
||||||
$this->headers[] = $header;
|
$this->headers[] = $header;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return $this;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Reference in New Issue
Block a user