Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Answer mail is treated as new thread when sent with Outlook #96

Open
leonex-cs1 opened this issue Sep 20, 2018 · 3 comments
Open

Answer mail is treated as new thread when sent with Outlook #96

leonex-cs1 opened this issue Sep 20, 2018 · 3 comments

Comments

@leonex-cs1
Copy link

Hi,
today I have sent an answer mail to the topic "[RFC] [VOTE] Typed properties v2" started 9 days ago by Bob Weinand. But anyhow #externals shows it as a new independant topic.

grafik

Can you tell me why this happened? What made I wrong?

I am using Outlook as mail client.

@mnapoli
Copy link
Owner

mnapoli commented Sep 20, 2018

Thanks for opening this issue, that happens from time to time with some emails. Maybe it's your email client, maybe something else 🤔

Here is the code that builds threads. It works by reading the References header:

// Reply to
$threadId = $emailId;
$inReplyTo = null;
$references = $parsedDocument->getHeaderValue('references');
if ($references) {
$references = preg_split('/(?<=>)/', $references);
$references = array_filter(array_map('trim', $references));
// Take the last item (the direct parent)
if (! empty($references)) {
$threadId = reset($references);
$inReplyTo = end($references);
}
}

Here is an example of an answer to the same thread that was correctly recognized: https://externals.io/email/103180/source (it has the References header)

Your email doesn't have that header: https://externals.io/email/103192/source

(FYI you can view the source of each email by clicking the "view source" link on externals.io)

I have no idea how to help further. Are you replying by email, or are you using the NNTP protocol?

@leonex-cs1
Copy link
Author

leonex-cs1 commented Sep 20, 2018 via email

@mnapoli
Copy link
Owner

mnapoli commented Sep 20, 2018

Sure, I won't work on that myself but if you have time for a pull request I'd gladly merge it!

@mnapoli mnapoli changed the title Answer Mail is treated as new Topic Answer mail is treated as new thread when sent with Outlook Sep 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants