mirror of
https://github.com/friendica/friendica
synced 2025-04-26 19:50:10 +00:00
Add expected method MailBuilder->withHeaders
- Address https://github.com/friendica/friendica/issues/9250#issuecomment-696055412
This commit is contained in:
parent
b8f3c4b065
commit
acd6fd7dd3
2 changed files with 33 additions and 3 deletions
|
@ -159,6 +159,36 @@ abstract class MailBuilder
|
|||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the current headers
|
||||
*
|
||||
* @return string[][]
|
||||
*/
|
||||
public function getHeaders()
|
||||
{
|
||||
return $this->headers;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the headers
|
||||
*
|
||||
* Expected format is
|
||||
* [
|
||||
* 'Header1' => ['value1', 'value2', ...],
|
||||
* 'Header2' => ['value3', 'value4', ...],
|
||||
* ...
|
||||
* ]
|
||||
*
|
||||
* @param string[][] $headers
|
||||
* @return $this
|
||||
*/
|
||||
public function withHeaders(array $headers)
|
||||
{
|
||||
$this->headers = $headers;
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Adds a value to a header
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue