Remove unused data elements
authorMichael M Slusarz <slusarz@curecanti.org>
Tue, 15 Dec 2009 01:01:19 +0000 (18:01 -0700)
committerMichael M Slusarz <slusarz@curecanti.org>
Tue, 15 Dec 2009 01:28:33 +0000 (18:28 -0700)
imp/js/DimpBase.js
imp/lib/Views/ShowMessage.php

index 96676c7..d4a5e00 100644 (file)
@@ -1144,8 +1144,7 @@ var DimpBase = {
         tmp.invoke('update', r.subject === null ? '[' + DIMP.text.badsubject + ']' : r.subject);
 
         // Add date
-        $('msgHeadersColl').select('.date').invoke('update', r.minidate);
-        $('msgHeaderDate').select('.date').invoke('update', r.localdate);
+        [ $('msgHeadersColl').select('.date'), $('msgHeaderDate').select('.date') ].flatten().invoke('update', r.localdate);
 
         // Add from/to/cc headers
         [ 'from', 'to', 'cc' ].each(function(a) {
index 9c93fbc..5c0d01a 100644 (file)
@@ -76,8 +76,7 @@ class IMP_Views_ShowMessage
      * 'uid' - The IMAP UID
      *
      * FOR PREVIEW MODE:
-     * 'fulldate' - The fully formatted date
-     * 'minidate' - A miniature date
+     * 'localdate' - The date formatted to the user's timezone
      *
      * FOR NON-PREVIEW MODE:
      * 'bcc' - The Bcc addresses
@@ -207,11 +206,11 @@ class IMP_Views_ShowMessage
         if ($preview) {
             /* Get minidate. */
             $imp_mailbox_ui = new IMP_Ui_Mailbox();
-            $minidate = $imp_mailbox_ui->getDate($envelope['date']);
-            if (empty($minidate)) {
-                $minidate = _("Unknown Date");
+            $localdate = $imp_mailbox_ui->getDate($envelope['date']);
+            if (empty($localdate)) {
+                $localdate = _("Unknown Date");
             }
-            $result['localdate'] = $result['minidate'] = htmlspecialchars($minidate);
+            $result['localdate'] = htmlspecialchars($localdate);
         } else {
             /* Display the user-specified headers for the current identity. */
             $user_hdrs = $imp_ui->getUserHeaders();