From 21601b4deb74555cfde23d3d7c9e255d5f98f5d2 Mon Sep 17 00:00:00 2001 From: Aleksander Machniak Date: Fri, 6 Sep 2013 18:21:09 +0200 Subject: Make cached message size limit configurable - messages_cache_threshold (#1489317) --- program/lib/Roundcube/rcube_imap.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'program/lib/Roundcube/rcube_imap.php') diff --git a/program/lib/Roundcube/rcube_imap.php b/program/lib/Roundcube/rcube_imap.php index 689a6266d..aa074233f 100644 --- a/program/lib/Roundcube/rcube_imap.php +++ b/program/lib/Roundcube/rcube_imap.php @@ -3785,9 +3785,10 @@ class rcube_imap extends rcube_storage if ($this->messages_caching && !$this->mcache) { $rcube = rcube::get_instance(); if (($dbh = $rcube->get_dbh()) && ($userid = $rcube->get_user_id())) { - $ttl = $rcube->config->get('messages_cache_ttl', '10d'); + $ttl = $rcube->config->get('messages_cache_ttl', '10d'); + $threshold = $rcube->config->get('messages_cache_threshold', 50); $this->mcache = new rcube_imap_cache( - $dbh, $this, $userid, $this->options['skip_deleted'], $ttl); + $dbh, $this, $userid, $this->options['skip_deleted'], $ttl, $threshold); } } -- cgit v1.2.3