MDL-56348 cache: Removed second parameter

There is no second parameter in the api
and identifier should be set by set_identifiers
This commit is contained in:
Rajesh Taneja 2016-10-11 11:00:39 +08:00
parent d9520bc04e
commit ca9a79dae3
No known key found for this signature in database
GPG Key ID: B363F7FB787F80E4
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;
}