/** * Gets a setting value * * @since 1.0 * * @param string $setting Optional. The setting to get. Defaults to an array of ALL settings. * @param mixed $default The value to be returned in the event that $setting doesn't exist. * @return mixed The value of the requested setting. If the setting could not be found, $default will be returned. */ public static function get($setting = null, $default = false) { self::$values = get_option(self::OPTION_NAME, array()); if (is_null($setting)) { return self::$values; } return isset(self::$values[$setting]) ? self::$values[$setting] : $default; }