mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-10 08:52:39 +01:00
Fix for email parsing from Outlook clients.
Summary: D1239 got it mostly right, but some versions of Outlook apparently put a '> ' in front of the 'Original Message' marker, which the parser couln't grok. Test Plan: Added a test case to the unit tests, applied the patch to my install and asked one of my heathen Outlook using colleagues to reply to a Conpherence post. Reviewers: epriestley, #blessed_reviewers Reviewed By: epriestley, #blessed_reviewers Subscribers: epriestley, Korvin Differential Revision: https://secure.phabricator.com/D8998
This commit is contained in:
parent
7f56bcd2d4
commit
a57cbbea8c
2 changed files with 10 additions and 2 deletions
|
@ -76,13 +76,13 @@ final class PhabricatorMetaMTAEmailBodyParser {
|
||||||
|
|
||||||
// Outlook english
|
// Outlook english
|
||||||
$body = preg_replace(
|
$body = preg_replace(
|
||||||
'/^\s*-----Original Message-----.*?/imsU',
|
'/^\s*(> )?-----Original Message-----.*?/imsU',
|
||||||
'',
|
'',
|
||||||
$body);
|
$body);
|
||||||
|
|
||||||
// Outlook danish
|
// Outlook danish
|
||||||
$body = preg_replace(
|
$body = preg_replace(
|
||||||
'/^\s*-----Oprindelig Meddelelse-----.*?/imsU',
|
'/^\s*(> )?-----Oprindelig Meddelelse-----.*?/imsU',
|
||||||
'',
|
'',
|
||||||
$body);
|
$body);
|
||||||
|
|
||||||
|
|
|
@ -168,6 +168,14 @@ OKAY
|
||||||
|
|
||||||
> On 17 Oct 2013, at 17:47, "Someone" <somebody@somewhere> wrote:
|
> On 17 Oct 2013, at 17:47, "Someone" <somebody@somewhere> wrote:
|
||||||
> ...
|
> ...
|
||||||
|
EOMAIL
|
||||||
|
,
|
||||||
|
<<<EOMAIL
|
||||||
|
OKAY
|
||||||
|
|
||||||
|
> -----Original Message-----
|
||||||
|
>
|
||||||
|
> ...
|
||||||
EOMAIL
|
EOMAIL
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue