Monotone-Parent: 1fb2ab16dbaee22f67d20e86943f297a72cf6c72
Monotone-Revision: 21e396c8605b155acfec0b2ce58b23eb13319cf3 Monotone-Author: wsourdeau@inverse.ca Monotone-Date: 2007-11-07T23:35:26 Monotone-Branch: ca.inverse.sogomaint-2.0.2
parent
38d3aa757e
commit
d66e63d3de
|
@ -1,5 +1,10 @@
|
|||
2007-11-07 Wolfgang Sourdeau <wsourdeau@inverse.ca>
|
||||
|
||||
* SoObjects/Appointments/SOGoAppointmentObject.m
|
||||
([SOGoAppointmentObject -saveContentString:_iCalinUIDs:_uids]):
|
||||
simplified method by directly building a similar appointment
|
||||
object with the current folder as container.
|
||||
|
||||
* SoObjects/Contacts/SOGoContactLDAPFolder.m
|
||||
([SOGoContactLDAPFolder
|
||||
-appendObject:objectwithBaseURL:baseURLtoREPORTResponse:r]):
|
||||
|
|
|
@ -106,43 +106,23 @@
|
|||
NSEnumerator *e;
|
||||
id folder;
|
||||
NSException *allErrors = nil;
|
||||
|
||||
NSException *error;
|
||||
SOGoAppointmentObject *apt;
|
||||
|
||||
e = [[container lookupCalendarFoldersForUIDs:_uids inContext: context]
|
||||
objectEnumerator];
|
||||
while ((folder = [e nextObject]) != nil) {
|
||||
NSException *error;
|
||||
SOGoAppointmentObject *apt;
|
||||
|
||||
if (![folder isNotNull]) /* no folder was found for given UID */
|
||||
continue;
|
||||
|
||||
apt = [folder lookupName: [self nameInContainer] inContext: context
|
||||
acquire: NO];
|
||||
if ([apt isKindOfClass: [NSException class]])
|
||||
{
|
||||
[self logWithFormat:@"Note: an exception occured finding '%@' in folder: %@",
|
||||
[self nameInContainer], folder];
|
||||
[self logWithFormat:@"the exception reason was: %@",
|
||||
[(NSException *) apt reason]];
|
||||
continue;
|
||||
}
|
||||
|
||||
if (![apt isNotNull]) {
|
||||
[self logWithFormat:@"Note: did not find '%@' in folder: %@",
|
||||
[self nameInContainer], folder];
|
||||
continue;
|
||||
while ((folder = [e nextObject]))
|
||||
{
|
||||
apt = [SOGoAppointmentObject objectWithName: nameInContainer
|
||||
inContainer: folder];
|
||||
error = [apt primarySaveContentString:_iCal];
|
||||
if (error)
|
||||
{
|
||||
[self logWithFormat:@"Note: failed to save iCal in folder: %@", folder];
|
||||
// TODO: make compound
|
||||
allErrors = error;
|
||||
}
|
||||
}
|
||||
if ([apt isKindOfClass: [NSException class]]) {
|
||||
[self logWithFormat:@"Exception: %@", [(NSException *) apt reason]];
|
||||
continue;
|
||||
}
|
||||
|
||||
if ((error = [apt primarySaveContentString:_iCal]) != nil) {
|
||||
[self logWithFormat:@"Note: failed to save iCal in folder: %@", folder];
|
||||
// TODO: make compound
|
||||
allErrors = error;
|
||||
}
|
||||
}
|
||||
|
||||
return allErrors;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue