lib/meibo/role_set.rb in meibo-0.1.0 vs lib/meibo/role_set.rb in meibo-0.2.0

- old
+ new

@@ -1,24 +1,17 @@ # frozen_string_literal: true module Meibo class RoleSet < DataSet - def initialize(data, organization_set:, user_set:, user_profile_set:) - super(data) - @organization_set = organization_set - @user_set = user_set - @user_profile_set = user_profile_set - end - def check_semantically_consistent super each do |role| - @organization_set.find_by_sourced_id(role.org_sourced_id) - @user_set.find_by_sourced_id(role.user_sourced_id) + roster.organizations.find(role.org_sourced_id) + roster.users.find(role.user_sourced_id) if role.user_profile_sourced_id - @user_profile_set.find_by_sourced_id(role.user_profile_sourced_id) + roster.user_profiles.find(role.user_profile_sourced_id) end end end end end