summaryrefslogtreecommitdiff
path: root/roundcubemail/program/include
diff options
context:
space:
mode:
authoralec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c>2011-07-06 07:50:34 +0000
committeralec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c>2011-07-06 07:50:34 +0000
commit807533d1e65c17cf2b06be88a3e2809c106a31d8 (patch)
tree0ea5b200b2703592b0d8fe54412023b42fe88f3d /roundcubemail/program/include
parentb1fdd78848424a35cb4986bb6949cf3d7defd967 (diff)
- Fix handling of other users namespace roots
git-svn-id: https://svn.roundcube.net/trunk@4911 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/program/include')
-rw-r--r--roundcubemail/program/include/rcube_imap.php15
1 files changed, 14 insertions, 1 deletions
diff --git a/roundcubemail/program/include/rcube_imap.php b/roundcubemail/program/include/rcube_imap.php
index 411be5202..710a434f2 100644
--- a/roundcubemail/program/include/rcube_imap.php
+++ b/roundcubemail/program/include/rcube_imap.php
@@ -3508,12 +3508,25 @@ class rcube_imap
foreach ($ns as $item) {
if ($item[0] === $mbox) {
$options['is_root'] = true;
- break;
+ break 2;
}
}
}
}
}
+ // check if the folder is other user virtual-root
+ if (!$options['is_root'] && !empty($namespace) && !empty($namespace['other'])) {
+ $parts = explode($this->delimiter, $mailbox);
+ if (count($parts) == 2) {
+ $mbox = $parts[0] . $this->delimiter;
+ foreach ($namespace['other'] as $item) {
+ if ($item[0] === $mbox) {
+ $options['is_root'] = true;
+ break;
+ }
+ }
+ }
+ }
$options['name'] = $mailbox;
$options['options'] = $this->mailbox_options($mailbox, true);