- marked as minor
imap folders missing when mixing dovecot with gmail
Hello,
I found a bug when I mixed Dovecot as primary account with Gmail as identity account: folders from Gmail are missing. (also from Synology MailPlus).
After a little research I found in session the following variables:
Bad setup for Gmail folders:
[imap_namespace] => Array
(
[personal] => Array
(
[0] => Array
(
[0] => INBOX.
[1] => .
)
)
[other] =>
[shared] =>
[prefix_in] => INBOX.
[prefix_out] => INBOX.
)
[imap_list_conf] => Array
(
[0] => INBOX.
[1] => Array
(
)
)
Good setup for Gmail folders:
[imap_namespace] => Array
(
[personal] => Array
(
[0] => Array
(
[0] =>
[1] => /
)
)
[other] =>
[shared] =>
[prefix_out] =>
)
[imap_delimiter] => /
[imap_list_conf] => Array
(
[0] =>
[1] => Array
(
)
)
These variables are not changing after identity change, maybe they need to be preserved and restored.
So my dirty fix was to add into file ident_switch.php at line 737 ( in function on_switch() after $_SESSION['iid' . self::MY_POSTFIX] = $r['iid'];)
$_SESSION['imap_namespace']="";
$_SESSION['imap_namespace']=array();
$_SESSION['imap_list_conf']="";
$_SESSION['imap_list_conf']=array();
Comments (4)
-
reporter -
repo owner Does your fix help you?
-
I experienced the same behavior as @Serafin Rusu . Using the fix provided, folders now appear and behave as expected for the gmail account.
Thank you!
-
reporter @Boris Gulay yes I just wanted to give back to community my fix.
- Log in to comment