modify cell cache getInstance() method to validate response from initialize() if it hasn't been called explicitly by a user call
git-svn-id: https://phpexcel.svn.codeplex.com/svn/trunk@83743 2327b42d-5241-43d6-9e2a-de5ac946f064
This commit is contained in:
parent
cd7f0a1c51
commit
fc62320de8
|
@ -125,12 +125,14 @@ class PHPExcel_CachedObjectStorageFactory {
|
||||||
|
|
||||||
public static function getInstance(PHPExcel_Worksheet $parent) {
|
public static function getInstance(PHPExcel_Worksheet $parent) {
|
||||||
if (is_null(self::$_cacheStorageMethod)) {
|
if (is_null(self::$_cacheStorageMethod)) {
|
||||||
self::initialize();
|
$cacheMethodIsAvailable = self::initialize();
|
||||||
}
|
}
|
||||||
|
|
||||||
$instance = new self::$_cacheStorageClass($parent,self::$_storageMethodParameters[self::$_cacheStorageMethod]);
|
if ($cacheMethodIsAvailable) {
|
||||||
if (!is_null($instance)) {
|
$instance = new self::$_cacheStorageClass($parent,self::$_storageMethodParameters[self::$_cacheStorageMethod]);
|
||||||
return $instance;
|
if (!is_null($instance)) {
|
||||||
|
return $instance;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
|
|
Loading…
Reference in New Issue