瀏覽代碼

Bugfix: Now special folders from sent subfolders plugin are correctly
recognized.

philippe_mingo 23 年之前
父節點
當前提交
137f07afc6
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2 2
      functions/imap_mailbox.php

+ 2 - 2
functions/imap_mailbox.php

@@ -24,11 +24,11 @@ function isSpecialMailbox( $box ) {
     if ( $move_to_sent  ) {
         $i = strpos( $sent_folder, $delimiter, strlen( $folder_prefix ) );
     }
-     
+     // echo '[' . substr( $sent_folder, 0, $i ) . '] (' . $box . ')'; 
     $ret = ( (strtolower($box) == 'inbox') ||
              ($box == $trash_folder &&
               $move_to_trash) ||
-             ( substr( $sent_folder, 0, max( $i, strlen( $box ) ) ) == $box &&
+             ( substr( $sent_folder, 0, $i ) == substr( $box, 0, $i ) &&
               $move_to_sent) ||
              ($box == $draft_folder &&
               $save_as_draft) );