diff --git a/ChangeLog b/ChangeLog index 21b0e22da..e5bbb49c3 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2009-05-05 Francis Lachapelle + + * SoObjects/SOGo/SOGoUser.m ([SOGoUser + +userWithLogin:roles:trust:]): don't set the roles if the passed + roles are not defined. + 2009-05-03 Francis Lachapelle * UI/Common/UIxUserRightsEditor.m ([UIxUserRightsEditor diff --git a/SoObjects/SOGo/LDAPUserManager.m b/SoObjects/SOGo/LDAPUserManager.m index 327c1254f..be16d0621 100644 --- a/SoObjects/SOGo/LDAPUserManager.m +++ b/SoObjects/SOGo/LDAPUserManager.m @@ -377,6 +377,7 @@ static NSLock *lock = nil; if (!access) [currentUser setObject: [NSNumber numberWithBool: NO] forKey: @"MailAccess"]; + break; } } diff --git a/SoObjects/SOGo/SOGoUser.m b/SoObjects/SOGo/SOGoUser.m index 5cfb94102..8a1e37611 100644 --- a/SoObjects/SOGo/SOGoUser.m +++ b/SoObjects/SOGo/SOGoUser.m @@ -238,14 +238,15 @@ _timeValue (NSString *key) user = [cache userNamed: newLogin]; if (!user) { - user = [[self alloc] initWithLogin: newLogin roles: newRoles trust: b]; + user = [[self alloc] initWithLogin: newLogin roles: newRoles trust: b]; if (user) { [user autorelease]; [cache registerUser: user]; } } - [user setPrimaryRoles: newRoles]; + if (newRoles) + [user setPrimaryRoles: newRoles]; return user; } diff --git a/UI/Common/UIxUserRightsEditor.m b/UI/Common/UIxUserRightsEditor.m index 6c8a80841..014d5f8f9 100644 --- a/UI/Common/UIxUserRightsEditor.m +++ b/UI/Common/UIxUserRightsEditor.m @@ -93,7 +93,7 @@ static BOOL sendACLAdvisories = NO; - (BOOL) _initRights { BOOL response; - NSString *newUID, *searchUID; + NSString *newUID; LDAPUserManager *um; SOGoObject *clientObject; SOGoGroup *group;