Check "Delivered-To" for identities (Closes #160)

This commit is contained in:
RainLoop Team 2014-05-24 02:37:10 +04:00
parent fed896776f
commit 2f074433a2
7 changed files with 105 additions and 80 deletions

View file

@ -78,6 +78,11 @@ class Message
*/
private $oReplyTo;
/**
* @var \MailSo\Mime\EmailCollection
*/
private $oDeliveredTo;
/**
* @var \MailSo\Mime\EmailCollection
*/
@ -201,6 +206,7 @@ class Message
$this->oFrom = null;
$this->oSender = null;
$this->oReplyTo = null;
$this->oDeliveredTo = null;
$this->oTo = null;
$this->oCc = null;
$this->oBcc = null;
@ -416,6 +422,14 @@ class Message
return $this->oReplyTo;
}
/**
* @return \MailSo\Mime\EmailCollection
*/
public function DeliveredTo()
{
return $this->oDeliveredTo;
}
/**
* @return \MailSo\Mime\EmailCollection
*/
@ -503,7 +517,7 @@ class Message
{
return $this->aThreads;
}
/**
* @param array $aThreads
*/
@ -535,7 +549,7 @@ class Message
{
return $this->iParentThread;
}
/**
* @param int $iParentThread
*/
@ -621,6 +635,7 @@ class Message
$this->oSender = $oHeaders->GetAsEmailCollection(\MailSo\Mime\Enumerations\Header::SENDER, $bCharsetAutoDetect);
$this->oReplyTo = $oHeaders->GetAsEmailCollection(\MailSo\Mime\Enumerations\Header::REPLY_TO, $bCharsetAutoDetect);
$this->oDeliveredTo = $oHeaders->GetAsEmailCollection(\MailSo\Mime\Enumerations\Header::DELIVERED_TO, $bCharsetAutoDetect);
$this->sInReplyTo = $oHeaders->ValueByName(\MailSo\Mime\Enumerations\Header::IN_REPLY_TO);
$this->sReferences = $oHeaders->ValueByName(\MailSo\Mime\Enumerations\Header::REFERENCES);
@ -687,7 +702,7 @@ class Message
{
$this->sReadReceipt = \trim($oHeaders->ValueByName(\MailSo\Mime\Enumerations\Header::X_CONFIRM_READING_TO));
}
$sDraftInfo = $oHeaders->ValueByName(\MailSo\Mime\Enumerations\Header::X_DRAFT_INFO);
if (0 < \strlen($sDraftInfo))
{
@ -766,7 +781,7 @@ class Message
{
$sTextCharset = $sCharset;
}
$sTextCharset = \MailSo\Base\Utils::NormalizeCharset($sTextCharset, true);
$sText = \MailSo\Base\Utils::DecodeEncodingValue($sText, $oPart->MailEncodingName());

View file

@ -21,6 +21,7 @@ class Header
const REPLY_TO = 'Reply-To';
const SENDER = 'Sender';
const RETURN_PATH = 'Return-Path';
const DELIVERED_TO = 'Delivered-To';
const MESSAGE_ID = 'Message-ID';
const IN_REPLY_TO = 'In-Reply-To';
@ -43,7 +44,7 @@ class Header
const MIME_VERSION = 'Mime-Version';
const X_MAILER = 'X-Mailer';
const X_MSMAIL_PRIORITY = 'X-MSMail-Priority';
const IMPORTANCE = 'Importance';
const X_PRIORITY = 'X-Priority';

View file

@ -6081,7 +6081,7 @@ class Actions
$aResult = array(
\RainLoop\Enumerations\Capa::PREM,
\RainLoop\Enumerations\Capa::FILTERS
// \RainLoop\Enumerations\Capa::FILTERS
);
if ($oConfig->Get('webmail', 'allow_additional_accounts', false))
@ -6989,6 +6989,7 @@ class Actions
'Cc' => $this->responseObject($mResponse->Cc(), $sParent, $aParameters),
'Bcc' => $this->responseObject($mResponse->Bcc(), $sParent, $aParameters),
'Sender' => $this->responseObject($mResponse->Sender(), $sParent, $aParameters),
'DeliveredTo' => $this->responseObject($mResponse->DeliveredTo(), $sParent, $aParameters),
'Priority' => $mResponse->Priority(),
'Threads' => $mResponse->Threads(),
'ThreadsLen' => $mResponse->ThreadsLen(),