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

Fix: Outlook date format #480

Merged
merged 2 commits into from
Nov 13, 2020
Merged

Fix: Outlook date format #480

merged 2 commits into from
Nov 13, 2020

Conversation

gajosadrian
Copy link
Contributor

Ddeboer\Imap\Exception\InvalidDateHeaderException

Invalid Date header found: "Tue, 27 Oct 2020 10:25:58 +0000 <AM8PR08MB56censored12829D160@AM8censored50.eurprd08.prod.outlook.com>"
imap_alerts (0):
imap_errors (0):
  at C:\xampp\htdocs\Modular-App\vendor\ddeboer\imap\src\Message\AbstractMessage.php:127
    123|
    124|         try {
    125|             $date = new \DateTimeImmutable($alteredValue);
    126|         } catch (\Throwable $ex) {
  > 127|             throw new InvalidDateHeaderException(\sprintf('Invalid Date header found: "%s"', $dateHeader), 0, $ex);
    128|         }
    129|
    130|         return $date;
    131|     }

Copy link
Collaborator

@Slamdunk Slamdunk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add the input and the expected ISO format into the corresponding test:

public function provideDateCases(): array

@Slamdunk Slamdunk merged commit 337b65d into ddeboer:master Nov 13, 2020
@Slamdunk Slamdunk added the bug label Nov 30, 2020
saintsloth pushed a commit to saintsloth/imap that referenced this pull request Oct 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants