public function get($name)
{
$name = trim($name);
if (isset($this->config->{$name})) {
return $this->config->{$name};
}
$value = null;
if (!isset($this->config->site_config_loaded)) {
$value = _elgg_services()->configTable->get($name);
}
// @todo document why we don't cache false
if ($value === false) {
return null;
}
$this->config->{$name} = $value;
return $value;
}
/** * Set up config appropriately on engine boot. * * @return void */ function init() { $lastcache = $this->config->get('lastcache'); if (!defined('UPGRADING') && empty($lastcache)) { $this->config->set('lastcache', (int) $this->datalist->get('simplecache_lastupdate')); } }