src/Admin/AdminPageHelper.php
public function getOption($optionName = null)
    {
        if ($this->multiSite) {
            $options = get_site_option($this->settingsName);
        } else {
            $options = get_option($this->settingsName);
        }
        if (!$optionName)
            return $options;

        if (is_array($options) && isset($options[$optionName]))
            return $options[$optionName];
        foreach ($this->settings as $setting) {
            if ($setting['name'] == $optionName) {
                if (!empty($setting['default']))
                    return $setting['default'];
                break;
            }
        }
        return null;
    }
public function getOption($optionName = null)
    {
        if ($this->multiSite) {
            $options = get_site_option($this->settingsName);
        } else {
            $options = get_option($this->settingsName);
        }
        if (!$optionName)
            return $options;

        if (is_array($options) && isset($options[$optionName]))
            return $options[$optionName];
        foreach ($this->settings as $setting) {
            if ($setting['name'] == $optionName) {
                if (!empty($setting['default']))
                    return $setting['default'];
                break;
            }
        }
        return null;
    }
public function getOption ( $ optionName = null ) { if ( $ this -> multiSite ) { $ options = get_site_option ( $ this -> settingsName ) ; } else { $ options = get_option ( $ this -> settingsName ) ; } if ( ! $ optionName ) return $ options ; if ( is_array ( $ options ) && isset ( $ options [ $ optionName ] ) ) return $ options [ $ optionName ] ; foreach ( $ this -> settings as $ setting ) { if ( $ setting [ 'name' ] == $ optionName ) { if ( ! empty ( $ setting [ 'default' ] ) ) return $ setting [ 'default' ] ; break ; } } return null ; }
Retrieve option value.
If the option is not set and a default was provided when adding the setting, it will be returned instead.

@param string $optionName
@return mixed
Retrieve option value . If the option is not set and a default was provided when adding the setting it will be returned instead .