mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-11-22 07:14:21 +00:00
Monotone-Parent: a8698cc119066cef660b176c3e956b5d0d843e7f
Monotone-Revision: f5b8996b9296ee950ea712c8de2c37e474163519 Monotone-Author: wsourdeau@inverse.ca Monotone-Date: 2009-08-27T21:14:54 Monotone-Branch: ca.inverse.sogo
This commit is contained in:
1 parent
a38722d9cb
commit
06b296ddba
19 files changed
+698
-145
No files matched your search
@@ -107,6 +107,7 @@ static SoSecurityManager *sm = nil;
|
||||
{
|
||||
subFolders = nil;
|
||||
OCSPath = nil;
|
||||
subscribedSubFolders = nil;
|
||||
subFolderClass = Nil;
|
||||
// hasSubscribedSources = NO;
|
||||
}
|
||||
@@ -116,6 +117,7 @@ static SoSecurityManager *sm = nil;
|
||||
|
||||
- (void) dealloc
|
||||
{
|
||||
[subscribedSubFolders release];
|
||||
[subFolders release];
|
||||
[OCSPath release];
|
||||
[super dealloc];
|
||||
@@ -353,29 +355,21 @@ static SoSecurityManager *sm = nil;
|
||||
|
||||
- (NSException *) initSubscribedSubFolders
|
||||
{
|
||||
NSArray *subscribedReferences;
|
||||
NSUserDefaults *settings;
|
||||
NSEnumerator *allKeys;
|
||||
NSString *currentKey, *login;
|
||||
NSString *login;
|
||||
NSException *error;
|
||||
|
||||
if (!subFolderClass)
|
||||
subFolderClass = [[self class] subFolderClass];
|
||||
|
||||
error = nil; /* we ignore non-DB errors at this time... */
|
||||
login = [[context activeUser] login];
|
||||
|
||||
if (!subscribedSubFolders && [login isEqualToString: owner])
|
||||
{
|
||||
subscribedSubFolders = [NSMutableDictionary new];
|
||||
settings = [[context activeUser] userSettings];
|
||||
subscribedReferences = [[settings objectForKey: nameInContainer]
|
||||
objectForKey: @"SubscribedFolders"];
|
||||
if ([subscribedReferences isKindOfClass: [NSArray class]])
|
||||
{
|
||||
allKeys = [subscribedReferences objectEnumerator];
|
||||
while ((currentKey = [allKeys nextObject]))
|
||||
[self _appendSubscribedSource: currentKey];
|
||||
}
|
||||
error = [self appendSubscribedSources];
|
||||
}
|
||||
|
||||
|
||||
return error;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user