fix for thread pref not kicking in on INBOX
authorjmunro <jmunro@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Wed, 3 Apr 2002 15:47:46 +0000 (15:47 +0000)
committerjmunro <jmunro@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Wed, 3 Apr 2002 15:47:46 +0000 (15:47 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@2676 7612ce4b-ef26-0410-bec9-ea0150e637f0

src/right_main.php

index fb7b809fb71d143d37ed8bc55f968eb65ed87040..01d7634c428b410543a59abc12eaf0e5b3e0f7e3 100644 (file)
@@ -47,6 +47,26 @@ if (isset($newsort) && $newsort != $sort) {
     setPref($data_dir, $username, 'sort', $newsort);
 }
 
+
+
+/* If the page has been loaded without a specific mailbox, */
+/* send them to the inbox                                  */
+if (!isset($mailbox)) {
+    $mailbox = 'INBOX';
+    $startMessage = 1;
+}
+
+
+if (!isset($startMessage) || ($startMessage == '')) {
+    $startMessage = 1;
+}
+
+/* compensate for the UW vulnerability. */
+if ($imap_server_type == 'uw' && (strstr($mailbox, '../') ||
+                                  substr($mailbox, 0, 1) == '/')) {
+   $mailbox = 'INBOX';
+}
+
 /* decide if we are thread sorting or not */
 global $allow_thread_sort;
 if ($allow_thread_sort == TRUE) {
@@ -68,30 +88,11 @@ else {
     $thread_sort_messages = 0;
 } 
 
-
-/* If the page has been loaded without a specific mailbox, */
-/* send them to the inbox                                  */
-if (!isset($mailbox)) {
-    $mailbox = 'INBOX';
-    $startMessage = 1;
+global $color;
+if( isset($do_hook) && $do_hook ) {
+    do_hook ("generic_header");
 }
 
-
-if (!isset($startMessage) || ($startMessage == '')) {
-    $startMessage = 1;
-}
-
-/* compensate for the UW vulnerability. */
-if ($imap_server_type == 'uw' && (strstr($mailbox, '../') ||
-                                  substr($mailbox, 0, 1) == '/')) {
-   $mailbox = 'INBOX';
-}
-    global $color;
-
-    if( isset($do_hook) && $do_hook ) {
-        do_hook ("generic_header");
-    }
-
 sqimap_mailbox_select($imapConnection, $mailbox);
 
 if (isset($composenew)) {