mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-08-29 02:07:36 +00:00
@@ -513,31 +513,6 @@ convention:
|
||||
flattenedValuesForKey: @""]
|
||||
inLDIFRecord: ldifRecord];
|
||||
|
||||
elements = [self childrenWithTag: @"adr"
|
||||
andAttribute: @"type" havingValue: @"work"];
|
||||
if (elements && [elements count] > 0)
|
||||
{
|
||||
element = [elements objectAtIndex: 0];
|
||||
[self _setValue: @"mozillaworkstreet2"
|
||||
to: [element flattenedValueAtIndex: 1 forKey: @""]
|
||||
inLDIFRecord: ldifRecord];
|
||||
[self _setValue: @"street"
|
||||
to: [element flattenedValueAtIndex: 2 forKey: @""]
|
||||
inLDIFRecord: ldifRecord];
|
||||
[self _setValue: @"l"
|
||||
to: [element flattenedValueAtIndex: 3 forKey: @""]
|
||||
inLDIFRecord: ldifRecord];
|
||||
[self _setValue: @"st"
|
||||
to: [element flattenedValueAtIndex: 4 forKey: @""]
|
||||
inLDIFRecord: ldifRecord];
|
||||
[self _setValue: @"postalcode"
|
||||
to: [element flattenedValueAtIndex: 5 forKey: @""]
|
||||
inLDIFRecord: ldifRecord];
|
||||
[self _setValue: @"c"
|
||||
to: [element flattenedValueAtIndex: 6 forKey: @""]
|
||||
inLDIFRecord: ldifRecord];
|
||||
}
|
||||
|
||||
elements = [self childrenWithTag: @"adr"
|
||||
andAttribute: @"type" havingValue: @"home"];
|
||||
if (elements && [elements count] > 0)
|
||||
@@ -563,6 +538,35 @@ convention:
|
||||
inLDIFRecord: ldifRecord];
|
||||
}
|
||||
|
||||
elements = [self childrenWithTag: @"adr"
|
||||
andAttribute: @"type" havingValue: @"work"];
|
||||
|
||||
if (!elements || [elements count] == 0)
|
||||
elements = [self childrenWithTag: @"adr"];
|
||||
|
||||
if (elements && [elements count] > 0)
|
||||
{
|
||||
element = [elements objectAtIndex: 0];
|
||||
[self _setValue: @"mozillaworkstreet2"
|
||||
to: [element flattenedValueAtIndex: 1 forKey: @""]
|
||||
inLDIFRecord: ldifRecord];
|
||||
[self _setValue: @"street"
|
||||
to: [element flattenedValueAtIndex: 2 forKey: @""]
|
||||
inLDIFRecord: ldifRecord];
|
||||
[self _setValue: @"l"
|
||||
to: [element flattenedValueAtIndex: 3 forKey: @""]
|
||||
inLDIFRecord: ldifRecord];
|
||||
[self _setValue: @"st"
|
||||
to: [element flattenedValueAtIndex: 4 forKey: @""]
|
||||
inLDIFRecord: ldifRecord];
|
||||
[self _setValue: @"postalcode"
|
||||
to: [element flattenedValueAtIndex: 5 forKey: @""]
|
||||
inLDIFRecord: ldifRecord];
|
||||
[self _setValue: @"c"
|
||||
to: [element flattenedValueAtIndex: 6 forKey: @""]
|
||||
inLDIFRecord: ldifRecord];
|
||||
}
|
||||
|
||||
elements = [self childrenWithTag: @"url"];
|
||||
[self _setValue: @"mozillaworkurl"
|
||||
to: [self _simpleValueForType: @"work" inArray: elements
|
||||
|
||||
@@ -47,7 +47,6 @@
|
||||
#import <SOGo/NSObject+DAV.h>
|
||||
#import <SOGo/SOGoPermissions.h>
|
||||
#import <SOGo/SOGoSource.h>
|
||||
#import <SOGo/SOGoUserManager.h>
|
||||
#import <SOGo/SOGoUserSettings.h>
|
||||
#import <SOGo/SOGoSystemDefaults.h>
|
||||
#import <SOGo/WORequest+SOGo.h>
|
||||
@@ -227,16 +226,8 @@
|
||||
NSObject <SOGoSource> *recordSource;
|
||||
|
||||
newRecord = [NSMutableDictionary dictionaryWithCapacity: 8];
|
||||
|
||||
// We set the c_uid only for authentication sources. SOGoUserSources set
|
||||
// with canAuthenticate = NO and isAddressBook = YES have absolutely *NO REASON*
|
||||
// to have entries with a c_uid. These can collide with real uids.
|
||||
if ([[[[SOGoUserManager sharedUserManager] metadataForSourceID: [source sourceID]] objectForKey: @"canAuthenticate"] boolValue])
|
||||
{
|
||||
[newRecord setObject: [oldRecord objectForKey: @"c_uid"]
|
||||
forKey: @"c_uid"];
|
||||
}
|
||||
|
||||
[newRecord setObject: [oldRecord objectForKey: @"c_uid"]
|
||||
forKey: @"c_uid"];
|
||||
[newRecord setObject: [oldRecord objectForKey: @"c_name"]
|
||||
forKey: @"c_name"];
|
||||
|
||||
|
||||
Reference in New Issue
Block a user