*/
protected $cacheHelper;
+ /**
+ * If the cache is enabled or not.
+ *
+ * @since 1.20
+ * @var boolean
+ */
+ protected $cacheEnabled = true;
+
/**
* Sets if the cache should be enabled or not.
*
* @param boolean|null $cacheEnabled Sets if the cache should be enabled or not.
*/
public function startCache( $cacheExpiry = null, $cacheEnabled = null ) {
- $this->cacheHelper = new CacheHelper( $this->get );
+ $this->cacheHelper = new CacheHelper();
+ $this->cacheHelper->setCacheEnabled( $this->cacheEnabled );
$this->cacheHelper->setOnInitializedHandler( array( $this, 'onCacheInitialized' ) );
$keyArgs = $this->getCacheKey();
*/
protected $cacheHelper;
+ /**
+ * If the cache is enabled or not.
+ *
+ * @since 1.20
+ * @var boolean
+ */
+ protected $cacheEnabled = true;
+
/**
* Sets if the cache should be enabled or not.
*
* @param boolean|null $cacheEnabled Sets if the cache should be enabled or not.
*/
public function startCache( $cacheExpiry = null, $cacheEnabled = null ) {
- $this->cacheHelper = new CacheHelper( $this->get );
+ $this->cacheHelper = new CacheHelper();
+ $this->cacheHelper->setCacheEnabled( $this->cacheEnabled );
$this->cacheHelper->setOnInitializedHandler( array( $this, 'onCacheInitialized' ) );
$keyArgs = $this->getCacheKey();