Project

General

Profile

« Previous | Next » 

Revision 3d58e226

Added by Marc Dequènes almost 15 years ago

  • ID 3d58e22672318af63b3682a7a89766525a7355fa

[fix] fs aspect primaryGroup corrected, and now handle single-valued relation data, and btw disallow adding the same value multiple times

View differences:

conf/ldap_shadows/hooks/aspects/fs.rb
DEFAULT_GROUP = 'dc-users'
def self.hook_mod(mapper, item)
# does not work, but why ?
unless item.attribute_present?('gidNumber')
item.primaryGroup = [mapper.find_klass(:group).find(:first, DEFAULT_GROUP)]
item.primaryGroup = mapper.find_klass(:group).find(:first, DEFAULT_GROUP)
end
unless item.attribute_present?('uidNumber')

Also available in: Unified diff