Use PHP functions

This commit is contained in:
Amine Ben hammou
2019-05-21 09:04:26 +00:00
committed by M. Shull
parent 879a36e0f2
commit 5d1623a083
2 changed files with 2 additions and 6 deletions

View File

@@ -35,7 +35,7 @@ class SettingsController {
}
}
if (is_array($setting) && is_array($default)) {
return WPFunctions::get()->arrayReplaceRecursive($default, $setting);
return array_replace_recursive($default, $setting);
}
return $setting;
}
@@ -85,7 +85,7 @@ class SettingsController {
function getAll() {
$this->ensureLoaded();
return WPFunctions::get()->arrayReplaceRecursive($this->getAllDefaults(), self::$settings);
return array_replace_recursive($this->getAllDefaults(), self::$settings);
}
function set($key, $value) {