lib/tracker_api/endpoints/memberships.rb in tracker_api-0.2.9 vs lib/tracker_api/endpoints/memberships.rb in tracker_api-0.2.10

- old
+ new

@@ -13,8 +13,14 @@ data.map do |membership| Resources::ProjectMembership.new({ project_id: project_id }.merge(membership)) end end + + def add(project_id, params={}) + data = client.post("/projects/#{project_id}/memberships", params: params).body + + Resources::ProjectMembership.new({ project_id: project_id }.merge(data)) + end end end end