mirror of
https://github.com/itflow-org/itflow
synced 2026-03-02 20:04:53 +00:00
Do not mark unprocessed email as read
This commit is contained in:
@@ -336,7 +336,7 @@ if ($emails) {
|
|||||||
$email_processed = false;
|
$email_processed = false;
|
||||||
|
|
||||||
// Get details from message and invoke PHP Mime Mail Parser
|
// Get details from message and invoke PHP Mime Mail Parser
|
||||||
$msg_to_parse = imap_fetchheader($imap, $email, FT_PREFETCHTEXT) . imap_body($imap, $email);
|
$msg_to_parse = imap_fetchheader($imap, $email, FT_PREFETCHTEXT) . imap_body($imap, $email, FT_PEEK);
|
||||||
$parser = new PhpMimeMailParser\Parser();
|
$parser = new PhpMimeMailParser\Parser();
|
||||||
$parser->setText($msg_to_parse);
|
$parser->setText($msg_to_parse);
|
||||||
|
|
||||||
@@ -430,6 +430,7 @@ if ($emails) {
|
|||||||
|
|
||||||
// Deal with the message (move it if processed, flag it if not)
|
// Deal with the message (move it if processed, flag it if not)
|
||||||
if ($email_processed) {
|
if ($email_processed) {
|
||||||
|
imap_setflag_full($imap, $email, "\\Seen");
|
||||||
imap_mail_move($imap, $email, $imap_folder);
|
imap_mail_move($imap, $email, $imap_folder);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user