mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-17 01:54:49 +00:00
accept single item in backup_config_section_xmlrpc
This commit is contained in:
parent
1b7e9e25cd
commit
1c44ae4ea4
@ -278,6 +278,11 @@ function backup_config_section_xmlrpc($sectionKeys)
|
||||
{
|
||||
global $config;
|
||||
require_once("config.inc");
|
||||
|
||||
return array_intersect_key($config, array_flip($sectionKeys));
|
||||
if (!is_array($sectionKeys)) {
|
||||
// single item
|
||||
return array_intersect_key($config, array($sectionKeys => 0));
|
||||
} else {
|
||||
// backup more sections at once
|
||||
return array_intersect_key($config, array_flip($sectionKeys));
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user