diff --git a/ChangeLog b/ChangeLog index 93ede8750..c3d667884 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2007-08-07 Wolfgang Sourdeau + + * UI/Contacts/UIxContactFoldersView.m ([UIxContactFoldersView + -_gcsFoldersFromFolder:): ignore the personal folders who are + returned but don't really exist. + 2007-08-02 Francis Lachapelle * UI/Contacts/UIxContactFoldersView.m ([UIxContactFoldersView _responseForResults:]): diff --git a/UI/Contacts/UIxContactFoldersView.m b/UI/Contacts/UIxContactFoldersView.m index 385a49554..ed6dcd9d4 100644 --- a/UI/Contacts/UIxContactFoldersView.m +++ b/UI/Contacts/UIxContactFoldersView.m @@ -205,15 +205,18 @@ if ([currentContactFolder isKindOfClass: [SOGoContactGCSFolder class]]) { - folderName = [NSString stringWithFormat: @"/Contacts/%@", - [currentContactFolder nameInContainer]]; - currentDictionary = [NSMutableDictionary new]; - [currentDictionary autorelease]; displayName = [[currentContactFolder ocsFolder] folderName]; - [currentDictionary setObject: displayName forKey: @"displayName"]; - [currentDictionary setObject: folderName forKey: @"name"]; - [currentDictionary setObject: @"contact" forKey: @"type"]; - [gcsFolders addObject: currentDictionary]; + if (displayName) + { + folderName = [NSString stringWithFormat: @"/Contacts/%@", + [currentContactFolder nameInContainer]]; + currentDictionary + = [NSMutableDictionary dictionaryWithCapacity: 3]; + [currentDictionary setObject: displayName forKey: @"displayName"]; + [currentDictionary setObject: folderName forKey: @"name"]; + [currentDictionary setObject: @"contact" forKey: @"type"]; + [gcsFolders addObject: currentDictionary]; + } } currentContactFolder = [contactSubfolders nextObject]; }