This commit is contained in:
Eloy Lafuente (stronk7) 2016-10-18 01:10:23 +02:00
commit b3a089e864
2 changed files with 6 additions and 4 deletions

View File

@ -198,7 +198,7 @@ class cache_factory {
}
$definition = $this->create_definition($component, $area);
$definition->set_identifiers($identifiers);
$cache = $this->create_cache($definition, $identifiers);
$cache = $this->create_cache($definition);
// Loaders are always held onto to speed up subsequent requests.
$this->cachesfromdefinitions[$definitionname] = $cache;
return $cache;
@ -227,7 +227,7 @@ class cache_factory {
}
$definition = cache_definition::load_adhoc($mode, $component, $area, $options);
$definition->set_identifiers($identifiers);
$cache = $this->create_cache($definition, $identifiers);
$cache = $this->create_cache($definition);
$this->cachesfromparams[$key] = $cache;
return $cache;
}

View File

@ -213,7 +213,8 @@ class cache_factory_disabled extends cache_factory {
*/
public function create_cache_from_definition($component, $area, array $identifiers = array(), $unused = null) {
$definition = $this->create_definition($component, $area);
$cache = $this->create_cache($definition, $identifiers);
$definition->set_identifiers($identifiers);
$cache = $this->create_cache($definition);
return $cache;
}
@ -233,7 +234,8 @@ class cache_factory_disabled extends cache_factory {
*/
public function create_cache_from_params($mode, $component, $area, array $identifiers = array(), array $options = array()) {
$definition = cache_definition::load_adhoc($mode, $component, $area);
$cache = $this->create_cache($definition, $identifiers);
$definition->set_identifiers($identifiers);
$cache = $this->create_cache($definition);
return $cache;
}