lib/wcc/media/client.rb in wcc-media-client-0.1.0 vs lib/wcc/media/client.rb in wcc-media-client-0.1.1
- old
+ new
@@ -44,11 +44,11 @@
end
def message(id)
resp = get("messages/#{id}")
resp.assert_ok!
- WCC::Media::Message.new(resp.body['message'])
+ WCC::Media::Message.new(resp.body['message'], resp.headers.freeze)
end
SERIES_FILTERS = %w[
begin_on_or_before_date
begin_on_or_after_date
@@ -70,11 +70,11 @@
end
def series(id)
resp = get("series/#{id}")
resp.assert_ok!
- WCC::Media::Series.new(resp.body['series'])
+ WCC::Media::Series.new(resp.body['series'], resp.headers.freeze)
end
SPEAKERS_FILTERS = %w[
featured
name_like
@@ -90,11 +90,11 @@
end
def speaker(id)
resp = get("speakers/#{id}")
resp.assert_ok!
- WCC::Media::Speaker.new(resp.body['speaker'])
+ WCC::Media::Speaker.new(resp.body['speaker'], resp.headers.freeze)
end
TAGS_FILTERS = %w[
name_like
]
@@ -108,10 +108,10 @@
end
def tag(id)
resp = get("tags/#{id}")
resp.assert_ok!
- WCC::Media::Tag.new(resp.body['tag'])
+ WCC::Media::Tag.new(resp.body['tag'], resp.headers.freeze)
end
private
def extract_params(filters)
\ No newline at end of file