(fix) respect the LDAP attributes mapping in the list view

This commit is contained in:
Ludovic Marcotte
2016-03-18 12:37:21 -04:00
parent 7d383639b9
commit 5ae40a02ec
3 changed files with 20 additions and 8 deletions
+4 -4
View File
@@ -972,7 +972,7 @@ groupObjectClasses: (NSArray *) newGroupObjectClasses
}
/* conversion LDAP -> SOGo inetOrgPerson entry */
- (void) _applyContactMappingToResult: (NSMutableDictionary *) ldifRecord
- (void) applyContactMappingToResult: (NSMutableDictionary *) ldifRecord
{
NSArray *sourceFields;
NSArray *keys;
@@ -1172,7 +1172,7 @@ groupObjectClasses: (NSArray *) newGroupObjectClasses
intoLDIFRecord: (NSMutableDictionary *) ldifRecord];
if (contactMapping)
[self _applyContactMappingToResult: ldifRecord];
[self applyContactMappingToResult: ldifRecord];
return ldifRecord;
}
@@ -1496,7 +1496,7 @@ _convertRecordToLDAPAttributes (LDAPSourceSchema *schema, NSDictionary *ldifReco
[ldifRecord setObject: aId forKey: @"cn"];
}
[self _applyContactMappingToOutput: ldifRecord];
[self applyContactMappingToOutput: ldifRecord];
/* since the id might have changed due to the mapping above, we
reload the record ID */
@@ -1604,7 +1604,7 @@ _makeLDAPChanges (NGLdapConnection *ldapConnection,
ldapConnection = [self _ldapConnection];
ldifRecord = [roLdifRecord mutableCopy];
[ldifRecord autorelease];
[self _applyContactMappingToOutput: ldifRecord];
[self applyContactMappingToOutput: ldifRecord];
attributes = _convertRecordToLDAPAttributes (schema, ldifRecord);
changes = _makeLDAPChanges (ldapConnection, dn, attributes);