mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-07-03 15:54:18 +00:00
Monotone-Parent: 717b1106bd82a838188f97c4b88f9caa35e59586
Monotone-Revision: 459d0175f983b6e31e8957fa80969a4b335469cb Monotone-Author: flachapelle@inverse.ca Monotone-Date: 2008-10-03T23:12:11 Monotone-Branch: ca.inverse.sogo
This commit is contained in:
@@ -34,6 +34,7 @@
|
||||
#import "LDAPUserManager.h"
|
||||
|
||||
static NSString *defaultMailDomain = nil;
|
||||
static NSString *LDAPContactInfoAttribute = nil;
|
||||
static BOOL defaultMailDomainIsConfigured = NO;
|
||||
static BOOL forceImapLoginWithEmail = NO;
|
||||
|
||||
@@ -49,13 +50,16 @@ static BOOL forceImapLoginWithEmail = NO;
|
||||
defaultMailDomain = [ud stringForKey: @"SOGoDefaultMailDomain"];
|
||||
[defaultMailDomain retain];
|
||||
defaultMailDomainIsConfigured = YES;
|
||||
}
|
||||
if (!defaultMailDomain)
|
||||
{
|
||||
[self warnWithFormat:
|
||||
@"no domain specified for SOGoDefaultMailDomain,"
|
||||
@" value set to 'localhost'"];
|
||||
defaultMailDomain = @"localhost";
|
||||
|
||||
if (!defaultMailDomain)
|
||||
{
|
||||
[self warnWithFormat:
|
||||
@"no domain specified for SOGoDefaultMailDomain,"
|
||||
@" value set to 'localhost'"];
|
||||
defaultMailDomain = @"localhost";
|
||||
}
|
||||
|
||||
LDAPContactInfoAttribute = [ud stringForKey: @"SOGoLDAPContactInfoAttribute"];
|
||||
}
|
||||
if (!forceImapLoginWithEmail)
|
||||
forceImapLoginWithEmail = [ud boolForKey: @"SOGoForceIMAPLoginWithEmail"];
|
||||
@@ -498,6 +502,11 @@ static BOOL forceImapLoginWithEmail = NO;
|
||||
email = [userEntry objectForKey: @"xmozillasecondemail"];
|
||||
if (email && ![emails containsObject: email])
|
||||
[emails addObject: email];
|
||||
if ([LDAPContactInfoAttribute length] > 0 &&
|
||||
[[returnContact objectForKey: LDAPContactInfoAttribute] length] > 0 &&
|
||||
[userEntry objectForKey: LDAPContactInfoAttribute] != nil)
|
||||
[returnContact setObject: [userEntry objectForKey: LDAPContactInfoAttribute]
|
||||
forKey: LDAPContactInfoAttribute];
|
||||
}
|
||||
|
||||
userEntry = [contacts nextObject];
|
||||
|
||||
Reference in New Issue
Block a user