summaryrefslogtreecommitdiff
path: root/roundcubemail/program/include/rcube_imap.php
diff options
context:
space:
mode:
authoralec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c>2011-05-09 08:32:13 +0000
committeralec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c>2011-05-09 08:32:13 +0000
commit2de1b0aafe81f8eb1d76585a742b3b4b674b6d22 (patch)
treee4152a62a944a2f5951afe465434cccb53c4c62d /roundcubemail/program/include/rcube_imap.php
parent6684a0409ad7c4fd2865603369db25c9dc0c59cf (diff)
- Fix possible ambiguity in folders caching (when list_mailboxes() was called the same result was returned, no matter what was the 1st and 2nd argument)
git-svn-id: https://svn.roundcube.net/trunk@4743 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/program/include/rcube_imap.php')
-rw-r--r--roundcubemail/program/include/rcube_imap.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/roundcubemail/program/include/rcube_imap.php b/roundcubemail/program/include/rcube_imap.php
index fbdaf34d5..ab2bc2a5e 100644
--- a/roundcubemail/program/include/rcube_imap.php
+++ b/roundcubemail/program/include/rcube_imap.php
@@ -3049,11 +3049,13 @@ class rcube_imap
*/
private function _list_mailboxes($root='', $name='*', $filter=null)
{
- $cache_key = 'mailboxes';
+ $cache_key = $root.':'.$name;
if (!empty($filter)) {
- $cache_key .= '.'.substr((is_string($filter) ? $filter : serialize($filter)), 0, 90);
+ $cache_key .= ':'.(is_string($filter) ? $filter : serialize($filter));
}
+ $cache_key = 'mailboxes.'.md5($cache_key);
+
// get cached folder list
$a_mboxes = $this->get_cache($cache_key);
if (is_array($a_mboxes)) {