lib/wcc/media/client.rb in wcc-media-client-0.4.9 vs lib/wcc/media/client.rb in wcc-media-client-0.4.10

- old
+ new

@@ -2,10 +2,11 @@ require_relative 'message' require_relative 'series' require_relative 'speaker' require_relative 'tag' require_relative 'playlist' +require_relative 'live_stream' require_relative 'client/response' module WCC module Media class Client < ::WCC::API::RestClient @@ -33,11 +34,12 @@ RESOURCES = { 'messages' => WCC::Media::Message, 'series' => WCC::Media::Series, 'speakers' => WCC::Media::Speaker, 'tags' => WCC::Media::Tag, - 'playlists' => WCC::Media::Playlist + 'playlists' => WCC::Media::Playlist, + 'streams' => WCC::Media::LiveStream }.freeze attr_reader(*RESOURCES.keys) attr_reader :options @@ -59,10 +61,10 @@ def find(id, **params) raise ArgumentError, "id param must be present, got: #{id}" unless id && /\S/.match(id.to_s) resp = client.get( "#{model.endpoint}/#{id}", - default_params('target').merge(params) + default_params('target').merge(params), ) resp.assert_ok! model.new(resp.body[model.key], resp.headers.freeze) end