Changeset fa2173c in github
- Timestamp:
- Oct 26, 2010 8:17:55 AM (3 years ago)
- Branches:
- master, HEAD, courier-fix, dev-browser-capabilities, pdo, release-0.6, release-0.7, release-0.8
- Children:
- 10a6fc58
- Parents:
- 4757608
- File:
-
- 1 edited
-
program/include/rcube_imap.php (modified) (10 diffs)
Legend:
- Unmodified
- Added
- Removed
-
program/include/rcube_imap.php
ra5a4bf4 rfa2173c 1260 1260 1261 1261 // we have a saved search result, get index from there 1262 if (!isset($this-> cache[$key]) && $this->search_string1262 if (!isset($this->icache[$key]) && $this->search_string 1263 1263 && !$this->search_threads && $mailbox == $this->mailbox) { 1264 1264 // use message index sort as default sorting … … 1270 1270 1271 1271 if ($this->sort_order == 'DESC') 1272 $this-> cache[$key] = array_reverse($msgs);1272 $this->icache[$key] = array_reverse($msgs); 1273 1273 else 1274 $this-> cache[$key] = $msgs;1274 $this->icache[$key] = $msgs; 1275 1275 } 1276 1276 // sort with SORT command … … 1280 1280 1281 1281 if ($this->sort_order == 'DESC') 1282 $this-> cache[$key] = array_reverse($this->search_set);1282 $this->icache[$key] = array_reverse($this->search_set); 1283 1283 else 1284 $this-> cache[$key] = $this->search_set;1284 $this->icache[$key] = $this->search_set; 1285 1285 } 1286 1286 else { … … 1294 1294 arsort($a_index); 1295 1295 1296 $this-> cache[$key] = array_keys($a_index);1296 $this->icache[$key] = array_keys($a_index); 1297 1297 } 1298 1298 else { 1299 $this-> cache[$key] = array();1299 $this->icache[$key] = array(); 1300 1300 } 1301 1301 } … … 1303 1303 1304 1304 // have stored it in RAM 1305 if (isset($this-> cache[$key]))1306 return $this-> cache[$key];1305 if (isset($this->icache[$key])) 1306 return $this->icache[$key]; 1307 1307 1308 1308 // check local cache … … 1328 1328 $a_index = array_reverse($a_index); 1329 1329 1330 $this-> cache[$key] = $a_index;1330 $this->icache[$key] = $a_index; 1331 1331 } 1332 1332 // fetch complete message index … … 1338 1338 $a_index = array_reverse($a_index); 1339 1339 1340 $this-> cache[$key] = $a_index;1340 $this->icache[$key] = $a_index; 1341 1341 } 1342 1342 else if ($a_index = $this->conn->fetchHeaderIndex( … … 1347 1347 arsort($a_index); 1348 1348 1349 $this-> cache[$key] = array_keys($a_index);1350 } 1351 1352 return $this-> cache[$key] !== false ? $this->cache[$key] : array();1349 $this->icache[$key] = array_keys($a_index); 1350 } 1351 1352 return $this->icache[$key] !== false ? $this->icache[$key] : array(); 1353 1353 } 1354 1354 … … 1370 1370 1371 1371 // we have a saved search result, get index from there 1372 if (!isset($this-> cache[$key]) && $this->search_string1372 if (!isset($this->icache[$key]) && $this->search_string 1373 1373 && $this->search_threads && $mailbox == $this->mailbox) { 1374 1374 // use message IDs for better performance 1375 1375 $ids = array_keys_recursive($this->search_set['tree']); 1376 $this-> cache[$key] = $this->_flatten_threads($mailbox, $this->search_set['tree'], $ids);1376 $this->icache[$key] = $this->_flatten_threads($mailbox, $this->search_set['tree'], $ids); 1377 1377 } 1378 1378 1379 1379 // have stored it in RAM 1380 if (isset($this-> cache[$key]))1381 return $this-> cache[$key];1380 if (isset($this->icache[$key])) 1381 return $this->icache[$key]; 1382 1382 /* 1383 1383 // check local cache … … 1394 1394 list ($thread_tree) = $this->_fetch_threads($mailbox); 1395 1395 1396 $this-> cache[$key] = $this->_flatten_threads($mailbox, $thread_tree);1397 1398 return $this-> cache[$key];1396 $this->icache[$key] = $this->_flatten_threads($mailbox, $thread_tree); 1397 1398 return $this->icache[$key]; 1399 1399 } 1400 1400
Note: See TracChangeset
for help on using the changeset viewer.
