From 3f5cef86665d068478fe7298f8b811e4de47b605 Mon Sep 17 00:00:00 2001
From: alecpl <alec@alec.pl>
Date: Sun, 13 Apr 2008 05:15:39 -0400
Subject: [PATCH] - reverted r1295 - disable caching for unseen messages to allow marking as read remarked messages

---
 program/steps/mail/show.inc |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/program/steps/mail/show.inc b/program/steps/mail/show.inc
index 1fe4aa9..a530184 100644
--- a/program/steps/mail/show.inc
+++ b/program/steps/mail/show.inc
@@ -30,7 +30,7 @@
   // set message charset as default
   if (!empty($MESSAGE['headers']->charset))
     $IMAP->set_charset($MESSAGE['headers']->charset);
-  
+
   // go back to list if message not found (wrong UID)
   if (!$MESSAGE['headers'])
     {
@@ -53,13 +53,13 @@
   $mbox_name = $IMAP->get_mailbox_name();
   
   // calculate Etag for this request
-  $etag = md5($MESSAGE['UID'].$mbox_name.session_id().intval($MESSAGE['headers']->mdn_sent).intval($MESSAGE['headers']->seen).intval($MESSAGE['is_safe']).intval($PRINT_MODE));
+  $etag = md5($MESSAGE['UID'].$mbox_name.session_id().intval($MESSAGE['headers']->mdn_sent).intval($MESSAGE['is_safe']).intval($PRINT_MODE));
 
   // allow caching, unless remote images are present
   if ((bool)$MESSAGE['is_safe'])
     send_nocacheing_headers();
   else if (empty($CONFIG['devel_mode']))
-    send_modified_header($_SESSION['login_time'], $etag);
+    send_modified_header($_SESSION['login_time'], $etag, !$MESSAGE['headers']->seen);
 
   $MESSAGE['subject'] = rcube_imap::decode_mime_string($MESSAGE['headers']->subject, $MESSAGE['headers']->charset);
   $OUTPUT->set_pagetitle($MESSAGE['subject']);

--
Gitblit v1.9.1