Class: Chef::ChefFS::DataHandler::OrganizationInvitesDataHandler

Inherits:
DataHandlerBase
  • Object
show all
Defined in:
lib/chef/chef_fs/data_handler/organization_invites_data_handler.rb

Instance Method Summary collapse

Methods inherited from DataHandlerBase

#chef_class, #chef_object, #default, #from_ruby, #normalize_for_post, #normalize_for_put, #normalize_hash, #normalize_run_list, #preserve_key?, #remove_file_extension, #to_ruby, #to_ruby_keys, #verify_integrity

Instance Method Details

#minimize(invites, entry) ⇒ Object



11
12
13
# File 'lib/chef/chef_fs/data_handler/organization_invites_data_handler.rb', line 11

def minimize(invites, entry)
  invites
end

#normalize(invites, entry) ⇒ Object



7
8
9
# File 'lib/chef/chef_fs/data_handler/organization_invites_data_handler.rb', line 7

def normalize(invites, entry)
  invites.map { |invite| invite.is_a?(Hash) ? invite["username"] : invite }.compact.sort.uniq
end