private function setSettings($settings)
    {
        if ($settings) {
            foreach ($this->settings as $key => &$value) {
                if (!empty($settings->{$key}) && $settings->{$key}) {
                    $value = $settings->{$key};
                }
            }
        }
    }
private function setSettings($settings)
    {
        if ($settings) {
            foreach ($this->settings as $key => &$value) {
                if (!empty($settings->{$key}) && $settings->{$key}) {
                    $value = $settings->{$key};
                }
            }
        }
    }
private function setSettings ( $ settings ) { if ( $ settings ) { foreach ( $ this -> settings as $ key => & $ value ) { if ( ! empty ( $ settings -> { $ key } ) && $ settings -> { $ key } ) { $ value = $ settings -> { $ key } ; } } } }
Retrieve API settings from the payload to override our defaults.

@param object $settings
Retrieve API settings from the payload to override our defaults .