mirror of
https://github.com/Combodo/iTop.git
synced 2026-02-13 07:24:13 +01:00
Prevent a warning when sending an email with no recipient in To:
SVN:trunk[3262]
This commit is contained in:
@@ -321,6 +321,11 @@ class EMail
|
|||||||
public function GetRecipientTO($bAsString = false)
|
public function GetRecipientTO($bAsString = false)
|
||||||
{
|
{
|
||||||
$aRes = $this->m_oMessage->getTo();
|
$aRes = $this->m_oMessage->getTo();
|
||||||
|
if ($aRes === false)
|
||||||
|
{
|
||||||
|
// There is no "To" header field
|
||||||
|
$aRes = array();
|
||||||
|
}
|
||||||
if ($bAsString)
|
if ($bAsString)
|
||||||
{
|
{
|
||||||
$aStrings = array();
|
$aStrings = array();
|
||||||
|
|||||||
@@ -595,6 +595,7 @@ class Swift_Mime_SimpleMimeEntity implements Swift_Mime_MimeEntity
|
|||||||
if ($this->_headers->has($field)) {
|
if ($this->_headers->has($field)) {
|
||||||
return $this->_headers->get($field)->getFieldBodyModel();
|
return $this->_headers->get($field)->getFieldBodyModel();
|
||||||
}
|
}
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user