lib/twilio-ruby/rest/pricing/v1/phone_number/country.rb in twilio-ruby-5.38.0 vs lib/twilio-ruby/rest/pricing/v1/phone_number/country.rb in twilio-ruby-5.39.0

- old
+ new

@@ -83,15 +83,13 @@ params = Twilio::Values.of({ 'PageToken' => page_token, 'Page' => page_number, 'PageSize' => page_size, }) - response = @version.page( - 'GET', - @uri, - params - ) + + response = @version.page('GET', @uri, params) + CountryPage.new(@version, response, @solution) end ## # Retrieve a single page of CountryInstance records from the API. @@ -157,21 +155,15 @@ @solution = {iso_country: iso_country, } @uri = "/PhoneNumbers/Countries/#{@solution[:iso_country]}" end ## - # Fetch a CountryInstance + # Fetch the CountryInstance # @return [CountryInstance] Fetched CountryInstance def fetch - params = Twilio::Values.of({}) + payload = @version.fetch('GET', @uri) - payload = @version.fetch( - 'GET', - @uri, - params, - ) - CountryInstance.new(@version, payload, iso_country: @solution[:iso_country], ) end ## # Provide a user friendly representation @@ -254,10 +246,10 @@ def url @properties['url'] end ## - # Fetch a CountryInstance + # Fetch the CountryInstance # @return [CountryInstance] Fetched CountryInstance def fetch context.fetch end \ No newline at end of file