Improve deleting occurences of recurrent events

This commit is contained in:
Francis Lachapelle committed 2014-02-04 17:55:49 -05:00
1 parent 4e42d5d410
commit ef1be5dc5f
25 files changed
+173 -91

No files matched your search

+8 -2
View File
@@ -788,16 +788,22 @@ static NSArray *childRecordFields = nil;
- (void) deleteEntriesWithIds: (NSArray *) ids
{
unsigned int count, max;
NSString *currentID;
NSEnumerator *names;
NSString *currentID, *currentName;
SOGoContentObject *deleteObject;
max = [ids count];
for (count = 0; count < max; count++)
{
currentID = [ids objectAtIndex: count];
deleteObject = [self lookupName: currentID
names = [[currentID componentsSeparatedByString: @"/"] objectEnumerator];
deleteObject = self;
while ((currentName = [names nextObject]))
{
deleteObject = [deleteObject lookupName: currentName
inContext: context
acquire: NO];
}
if (![deleteObject isKindOfClass: [NSException class]])
{
if ([deleteObject respondsToSelector: @selector (prepareDelete)])