Commit ca5333a7 authored by Sebastian Kummer's avatar Sebastian Kummer

Merge pull request #558 in ZP/z-push from bugfix/ZP-1250-send-as-is-detected-erroneously to develop

* commit 'e03948fc':
  ZP-1250 Search for X-Push-Sender only in the headers.
parents 603250a2 e03948fc
...@@ -444,7 +444,7 @@ class BackendKopano implements IBackend, ISearchProvider { ...@@ -444,7 +444,7 @@ class BackendKopano implements IBackend, ISearchProvider {
$senderEmail = array(); $senderEmail = array();
// KOE: grep for the Sender header indicating we should send-as // KOE: grep for the Sender header indicating we should send-as
// the 'X-Push-Sender-Name' header is not used // the 'X-Push-Sender-Name' header is not used
if (preg_match("/^X-Push-Sender:\s(.*?)$/im", $sm->mime, $senderEmail)) { if (preg_match("/^X-Push-Sender:\s(.*?)$/im", substr($sm->mime, 0, strpos($sm->mime, "\r\n\r\n")), $senderEmail)) {
$sendAsEmail = trim($senderEmail[1]); $sendAsEmail = trim($senderEmail[1]);
ZLog::Write(LOGLEVEL_DEBUG, sprintf("KopanoBackend->SendMail(): Send-As '%s' requested by KOE", $sendAsEmail)); ZLog::Write(LOGLEVEL_DEBUG, sprintf("KopanoBackend->SendMail(): Send-As '%s' requested by KOE", $sendAsEmail));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment