implemented new setting method
This commit is contained in:
@ -260,6 +260,22 @@ class SettingManager implements CallbackListener {
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the Setting Value directly
|
||||
*
|
||||
* @param mixed $object
|
||||
* @param string $settingName
|
||||
* @param mixed $default
|
||||
* @return mixed
|
||||
*/
|
||||
public function getSettingValue($object, $settingName, $default = null) {
|
||||
$setting = $this->getSetting($object, $settingName, $default);
|
||||
if ($setting) {
|
||||
return $setting->value;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Reset a Setting to its Default Value
|
||||
*
|
||||
|
Reference in New Issue
Block a user