mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-05-27 22:35:22 +00:00
Monotone-Parent: f6d4ca8944c94273bc0dae0565c60e45be9f2ca1
Monotone-Revision: 98896091d472e0ee7990f69f32f5981f5d1dc546 Monotone-Author: wsourdeau@inverse.ca Monotone-Date: 2008-01-16T18:46:32 Monotone-Branch: ca.inverse.sogo
This commit is contained in:
@@ -32,10 +32,11 @@
|
||||
|
||||
#import "AgenorUserDefaults.h"
|
||||
#import "LDAPUserManager.h"
|
||||
#import "NSArray+Utilities.h"
|
||||
#import "SOGoCache.h"
|
||||
#import "SOGoDateFormatter.h"
|
||||
#import "SOGoObject.h"
|
||||
#import "SOGoPermissions.h"
|
||||
#import "NSArray+Utilities.h"
|
||||
|
||||
#import "SOGoUser.h"
|
||||
|
||||
@@ -124,10 +125,18 @@ NSString *SOGoWeekStartFirstFullWeek = @"FirstFullWeek";
|
||||
+ (SOGoUser *) userWithLogin: (NSString *) newLogin
|
||||
roles: (NSArray *) newRoles
|
||||
{
|
||||
SOGoCache *cache;
|
||||
SOGoUser *user;
|
||||
|
||||
user = [[self alloc] initWithLogin: newLogin roles: newRoles];
|
||||
[user autorelease];
|
||||
cache = [SOGoCache sharedCache];
|
||||
user = [cache userNamed: newLogin];
|
||||
if (!user)
|
||||
{
|
||||
user = [[self alloc] initWithLogin: newLogin roles: newRoles];
|
||||
[user autorelease];
|
||||
[cache registerUser: user];
|
||||
}
|
||||
[user setPrimaryRoles: newRoles];
|
||||
|
||||
return user;
|
||||
}
|
||||
@@ -181,6 +190,11 @@ NSString *SOGoWeekStartFirstFullWeek = @"FirstFullWeek";
|
||||
[super dealloc];
|
||||
}
|
||||
|
||||
- (void) setPrimaryRoles: (NSArray *) newRoles
|
||||
{
|
||||
ASSIGN (roles, newRoles);
|
||||
}
|
||||
|
||||
- (void) setCurrentPassword: (NSString *) newPassword
|
||||
{
|
||||
ASSIGN (currentPassword, newPassword);
|
||||
|
||||
Reference in New Issue
Block a user