Removed more warnings
[squirrelmail.git] / src / left_main.php
index dac7f1e006d832a68689bbc0710636028897d98c..3d38e173f87a7952661bdc5e8b25c0af08035b76 100644 (file)
@@ -20,7 +20,7 @@
    
    displayHtmlHeader();
 
-   if ($auto_create_special) {
+   if ($auto_create_special && ! isset($auto_create_done)) {
          if (isset ($sent_folder) && $sent_folder != "none") {
                 if (!sqimap_mailbox_exists ($imapConnection, $sent_folder)) {
                        sqimap_mailbox_create ($imapConnection, $sent_folder, "");
@@ -31,6 +31,8 @@
                        sqimap_mailbox_create ($imapConnection, $trash_folder, "");
                 }
          }
+         $auto_create_done = true;
+         session_register('auto_create_done');
    }
 
    function formatMailboxName($imapConnection, $box_array, $delimeter) {