Updated core, API

This commit is contained in:
markseu 2018-06-13 11:12:33 +02:00
parent 349c510149
commit 7866751e1f

View file

@ -331,7 +331,7 @@ class YellowCore
if($this->config->get("startupUpdate")!="none")
{
$fileNameConfig = $this->config->get("configDir").$this->config->get("configFile");
$this->config->update($fileNameConfig, array("startupUpdate" => "none"));
$this->config->save($fileNameConfig, array("startupUpdate" => "none"));
}
}
@ -1887,8 +1887,8 @@ class YellowConfig
}
}
// Update configuration in file
function update($fileName, $config)
// Save configuration to file
function save($fileName, $config)
{
$configNew = new YellowDataCollection();
foreach($config as $key=>$value)
@ -1919,6 +1919,12 @@ class YellowConfig
return $this->yellow->toolbox->createFile($fileName, $fileDataNew);
}
// Update configuration in file, TODO: remove later, used for backwards compatibility
function update($fileName, $config)
{
$this->save($fileName, $config);
}
// Set default configuration
function setDefault($key, $value)
{