diff options
| author | brettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2011-02-14 05:23:16 +0000 | 
|---|---|---|
| committer | brettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2011-02-14 05:23:16 +0000 | 
| commit | 574e2eb0df4bc454e847e1974e04c0d85aa661f7 (patch) | |
| tree | 1de44458b294b175d55e8202e53559d083bce0cd /engine | |
| parent | 38e91f2b8f4972f5b1e0789aeac22056fe8d5c54 (diff) | |
| download | elgg-574e2eb0df4bc454e847e1974e04c0d85aa661f7.tar.gz elgg-574e2eb0df4bc454e847e1974e04c0d85aa661f7.tar.bz2  | |
Clearing caches in ElggBatch.
git-svn-id: http://code.elgg.org/elgg/trunk@8226 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine')
| -rw-r--r-- | engine/classes/ElggBatch.php | 7 | 
1 files changed, 7 insertions, 0 deletions
diff --git a/engine/classes/ElggBatch.php b/engine/classes/ElggBatch.php index 4f8f6cae9..a5051d16a 100644 --- a/engine/classes/ElggBatch.php +++ b/engine/classes/ElggBatch.php @@ -206,6 +206,13 @@ class ElggBatch  	 * @return bool  	 */  	private function getNextResultsChunk() { +		// reset memory caches after first chunk load +		if ($this->chunkIndex > 0) { +			global $DB_QUERY_CACHE, $ENTITY_CACHE; +			$DB_QUERY_CACHE = $ENTITY_CACHE = array(); +		} + +		// always reset results.  		$this->results = array();  		if (!isset($this->validGetter)) {  | 
