lib/twilio-ruby/rest/bulkexports/v1/export/day.rb in twilio-ruby-5.38.0 vs lib/twilio-ruby/rest/bulkexports/v1/export/day.rb in twilio-ruby-5.39.0
- old
+ new
@@ -103,15 +103,13 @@
'PreviousToken' => previous_token,
'PageToken' => page_token,
'Page' => page_number,
'PageSize' => page_size,
})
- response = @version.page(
- 'GET',
- @uri,
- params
- )
+
+ response = @version.page('GET', @uri, params)
+
DayPage.new(@version, response, @solution)
end
##
# Retrieve a single page of DayInstance records from the API.
@@ -181,21 +179,15 @@
@solution = {resource_type: resource_type, day: day, }
@uri = "/Exports/#{@solution[:resource_type]}/Days/#{@solution[:day]}"
end
##
- # Fetch a DayInstance
+ # Fetch the DayInstance
# @return [DayInstance] Fetched DayInstance
def fetch
- params = Twilio::Values.of({})
+ payload = @version.fetch('GET', @uri)
- payload = @version.fetch(
- 'GET',
- @uri,
- params,
- )
-
DayInstance.new(@version, payload, resource_type: @solution[:resource_type], day: @solution[:day], )
end
##
# Provide a user friendly representation
@@ -287,10 +279,10 @@
def resource_type
@properties['resource_type']
end
##
- # Fetch a DayInstance
+ # Fetch the DayInstance
# @return [DayInstance] Fetched DayInstance
def fetch
context.fetch
end
\ No newline at end of file