public function getProviderInfos($handle)
    {
        $record = $this->_getProviderRecordByHandle($handle);

        if($record)
        {
            return Oauth_ProviderInfosModel::populateModel($record);
        }
        else
        {
            $configProviderInfos = craft()->config->get('providerInfos', 'oauth');

            if(isset($configProviderInfos[$handle]))
            {
                $attributes = [];

                if(isset($configProviderInfos[$handle]['clientId']))
                {
                    $attributes['clientId'] = $configProviderInfos[$handle]['clientId'];
                }

                if(isset($configProviderInfos[$handle]['clientSecret']))
                {
                    $attributes['clientSecret'] = $configProviderInfos[$handle]['clientSecret'];
                }

                return Oauth_ProviderInfosModel::populateModel($attributes);
            }
        }
    }
public function getProviderInfos($handle)
    {
        $record = $this->_getProviderRecordByHandle($handle);

        if($record)
        {
            return Oauth_ProviderInfosModel::populateModel($record);
        }
        else
        {
            $configProviderInfos = craft()->config->get('providerInfos', 'oauth');

            if(isset($configProviderInfos[$handle]))
            {
                $attributes = [];

                if(isset($configProviderInfos[$handle]['clientId']))
                {
                    $attributes['clientId'] = $configProviderInfos[$handle]['clientId'];
                }

                if(isset($configProviderInfos[$handle]['clientSecret']))
                {
                    $attributes['clientSecret'] = $configProviderInfos[$handle]['clientSecret'];
                }

                return Oauth_ProviderInfosModel::populateModel($attributes);
            }
        }
    }
public function getProviderInfos ( $ handle ) { $ record = $ this -> _getProviderRecordByHandle ( $ handle ) ; if ( $ record ) { return Oauth_ProviderInfosModel :: populateModel ( $ record ) ; } else { $ configProviderInfos = craft ( ) -> config -> get ( 'providerInfos' , 'oauth' ) ; if ( isset ( $ configProviderInfos [ $ handle ] ) ) { $ attributes = [ ] ; if ( isset ( $ configProviderInfos [ $ handle ] [ 'clientId' ] ) ) { $ attributes [ 'clientId' ] = $ configProviderInfos [ $ handle ] [ 'clientId' ] ; } if ( isset ( $ configProviderInfos [ $ handle ] [ 'clientSecret' ] ) ) { $ attributes [ 'clientSecret' ] = $ configProviderInfos [ $ handle ] [ 'clientSecret' ] ; } return Oauth_ProviderInfosModel :: populateModel ( $ attributes ) ; } } }
Get provider infos
Get provider infos