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 imap date on POP3 #13

Merged
merged 1 commit into from
Sep 11, 2023
Merged

Fix imap date on POP3 #13

merged 1 commit into from
Sep 11, 2023

Conversation

bytestream
Copy link
Owner

$tmp['Date'] is an instance of Horde_Mime_Headers_Date which results in an incorrect type passed to setImapDate():

/**
 * Set IMAP internal date.
 *
 * @param mixed $date  Either a Horde_Imap_Client_DateTime object or a date string.
 */
public function setImapDate($date)
{
    $this->_data[Horde_Imap_Client::FETCH_IMAPDATE] = is_object($date)
        ? $date
        : new Horde_Imap_Client_DateTime($date);
}

Call getImapDate() on a POP3 socket using a fetch query of the below to replicate:

$query = new Horde_Imap_Client_Fetch_Query;
$query->imapDate();

@bytestream bytestream merged commit fed98c8 into master Sep 11, 2023
@bytestream bytestream deleted the imap-date-pop3 branch September 11, 2023 13:24
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

Successfully merging this pull request may close these issues.

1 participant