mirror of
https://github.com/PHPOffice/PhpSpreadsheet.git
synced 2026-09-21 15:49:26 +00:00
Bugfix: (manual merge from a pull request from amironov) Work item GH-82 - PHPExcel_Worksheet::getCellCollection() may not return last cached cell
This commit is contained in:
@@ -42,7 +42,7 @@ class PHPExcel_CachedObjectStorage_MemorySerialized extends PHPExcel_CachedObjec
|
||||
* @return void
|
||||
* @throws Exception
|
||||
*/
|
||||
private function _storeData() {
|
||||
protected function _storeData() {
|
||||
if ($this->_currentCellIsDirty) {
|
||||
$this->_currentObject->detach();
|
||||
|
||||
@@ -104,6 +104,20 @@ class PHPExcel_CachedObjectStorage_MemorySerialized extends PHPExcel_CachedObjec
|
||||
} // function getCacheData()
|
||||
|
||||
|
||||
/**
|
||||
* Get a list of all cell addresses currently held in cache
|
||||
*
|
||||
* @return array of string
|
||||
*/
|
||||
public function getCellList() {
|
||||
if ($this->_currentObjectID !== null) {
|
||||
$this->_storeData();
|
||||
}
|
||||
|
||||
return parent::getCellList();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Clear the cell collection and disconnect from our parent
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user