Some mail servers auto-create the Trash folder. With this tiny bit of code,
authorfidian <fidian@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Thu, 28 Jun 2001 18:47:53 +0000 (18:47 +0000)
committerfidian <fidian@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Thu, 28 Jun 2001 18:47:53 +0000 (18:47 +0000)
we automatically subscribe the Sent and Trash folders just in case they do
exist and aren't subscribed to.  It's just part of the one-time overhead
when logging in.

git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@1436 7612ce4b-ef26-0410-bec9-ea0150e637f0

src/left_main.php

index 3d38e173f87a7952661bdc5e8b25c0af08035b76..a227e4679b203402fc3c755256df6888c1607390 100644 (file)
          if (isset ($sent_folder) && $sent_folder != "none") {
                 if (!sqimap_mailbox_exists ($imapConnection, $sent_folder)) {
                        sqimap_mailbox_create ($imapConnection, $sent_folder, "");
+                } else {
+                   sqimap_subscribe($imapConnection, $sent_folder);
                 }
          }
          if (isset ($trash_folder) && $trash_folder != "none") {
                 if (!sqimap_mailbox_exists ($imapConnection, $trash_folder)) {
                        sqimap_mailbox_create ($imapConnection, $trash_folder, "");
+                } else {
+                   sqimap_subscribe($imapConnection, $trash_folder);
                 }
          }
          $auto_create_done = true;