class TrackerApi::Endpoints::Review
Attributes
client[RW]
Public Class Methods
new(client)
click to toggle source
# File lib/tracker_api/endpoints/review.rb, line 6 def initialize(client) @client = client end
Public Instance Methods
update(review, params = {})
click to toggle source
# File lib/tracker_api/endpoints/review.rb, line 10 def update(review, params = {}) raise ArgumentError, 'Valid review required to update.' unless review.instance_of?(Resources::Review) data = client.put("/projects/#{review.project_id}/stories/#{review.story_id}/reviews/#{review.id}", params: params).body review.attributes = data review.clean! review end