fix messed up addresses by horde for listview too

This commit is contained in:
Klaus Leithoff 2013-11-29 13:29:49 +00:00
parent d5eb20e3b2
commit ce226a3197

View File

@ -1109,6 +1109,24 @@ class mail_bo
$headerObject['FROM'] = $_headerObject->getEnvelope()->from->addresses; $headerObject['FROM'] = $_headerObject->getEnvelope()->from->addresses;
$headerObject['TO'] = $_headerObject->getEnvelope()->to->addresses; $headerObject['TO'] = $_headerObject->getEnvelope()->to->addresses;
$headerObject['CC'] = $_headerObject->getEnvelope()->cc->addresses; $headerObject['CC'] = $_headerObject->getEnvelope()->cc->addresses;
foreach (array('FROM','TO','CC') as $_k => $key)
{
$address = array();
foreach ($headerObject[$key] as $k => $ad)
{
if (stripos($ad,'@')===false)
{
$remember=$k;
}
else
{
$address[] = (!is_null($remember)?$headerObject[$key][$remember].' ':'').$ad;
$remember=null;
}
}
$headerObject[$key] = $address;
}
$headerObject['FLAGS'] = $_headerObject->getFlags(); $headerObject['FLAGS'] = $_headerObject->getFlags();
$mailStructureObject = $_headerObject->getStructure(); $mailStructureObject = $_headerObject->getStructure();
//error_log(__METHOD__.__LINE__.array2string($headerObject)); //error_log(__METHOD__.__LINE__.array2string($headerObject));