lib/kentaa/api/resources/team.rb in kentaa-api-0.4.0 vs lib/kentaa/api/resources/team.rb in kentaa-api-0.5.0

- old
+ new

@@ -11,18 +11,22 @@ "Team_#{id}" end def parent if project_id - Kentaa::Api::Resources::Project.new(config, id: project_id) + Kentaa::Api::Resources::Project.new(config, id: project_id, options: options) elsif segment_id - Kentaa::Api::Resources::Segment.new(config, id: segment_id) + Kentaa::Api::Resources::Segment.new(config, id: segment_id, options: options) else - Kentaa::Api::Resources::Site.new(config, id: site_id) + Kentaa::Api::Resources::Site.new(config, id: site_id, options: options) end end + def site + Kentaa::Api::Resources::Site.new(config, id: site_id, options: options) + end + def slug data[:slug] end def site_id @@ -36,19 +40,19 @@ def project_id data[:project_id] end def owner - @owner ||= Kentaa::Api::Resources::User.new(config, data: data[:owner]) + @owner ||= Kentaa::Api::Resources::User.new(config, data: data[:owner], options: options) end def members @members ||= begin members = [] if data[:members] data[:members].each do |member| - members << Kentaa::Api::Resources::Action.new(config, data: member) + members << Kentaa::Api::Resources::Action.new(config, data: member, options: options) end end members end