|
|
@ -58,10 +58,15 @@ int CardDavWriter::runJob(runtime_info* RT) {
|
|
|
|
res = pushObjects(mChanged, carddav_modify_object_by_uri, OK, RT);
|
|
|
|
res = pushObjects(mChanged, carddav_modify_object_by_uri, OK, RT);
|
|
|
|
if (OK == res) {
|
|
|
|
if (OK == res) {
|
|
|
|
kdDebug() << "pushing deleted objects";
|
|
|
|
kdDebug() << "pushing deleted objects";
|
|
|
|
if (getUseURI() == false)
|
|
|
|
while (mDeleted.contains("BEGIN:VCARD", TRUE) > 0) {
|
|
|
|
res = pushObjects(mDeleted, carddav_delete_object, OK, RT);
|
|
|
|
int endLocation = mDeleted.find("END:VCARD", 0, TRUE);
|
|
|
|
else
|
|
|
|
TQString deletedCurSeq = mDeleted.mid(0, endLocation+9);
|
|
|
|
res = pushObjects(mDeleted, carddav_delete_object_by_uri, OK, RT);
|
|
|
|
mDeleted = mDeleted.remove(0, endLocation+9);
|
|
|
|
|
|
|
|
if (getUseURI() == false)
|
|
|
|
|
|
|
|
res = pushObjects(deletedCurSeq, carddav_delete_object, OK, RT);
|
|
|
|
|
|
|
|
else
|
|
|
|
|
|
|
|
res = pushObjects(deletedCurSeq, carddav_delete_object_by_uri, OK, RT);
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#else // if USE_CARDDAV_MODIFY
|
|
|
|
#else // if USE_CARDDAV_MODIFY
|
|
|
|
kdDebug() << "pushing changed objects (delete)";
|
|
|
|
kdDebug() << "pushing changed objects (delete)";
|
|
|
@ -77,10 +82,15 @@ int CardDavWriter::runJob(runtime_info* RT) {
|
|
|
|
res = pushObjects(mChanged, carddav_add_object, OK, RT);
|
|
|
|
res = pushObjects(mChanged, carddav_add_object, OK, RT);
|
|
|
|
if (OK == res) {
|
|
|
|
if (OK == res) {
|
|
|
|
kdDebug() << "pushing deleted objects";
|
|
|
|
kdDebug() << "pushing deleted objects";
|
|
|
|
if (getUseURI() == false)
|
|
|
|
while (mDeleted.contains("BEGIN:VCARD", TRUE) > 0) {
|
|
|
|
res = pushObjects(mDeleted, carddav_delete_object, OK, RT);
|
|
|
|
int endLocation = mDeleted.find("END:VCARD", 0, TRUE);
|
|
|
|
else
|
|
|
|
TQString deletedCurSeq = mDeleted.mid(0, endLocation+9);
|
|
|
|
res = pushObjects(mDeleted, carddav_delete_object_by_uri, OK, RT);
|
|
|
|
mDeleted = mDeleted.remove(0, endLocation+9);
|
|
|
|
|
|
|
|
if (getUseURI() == false)
|
|
|
|
|
|
|
|
res = pushObjects(deletedCurSeq, carddav_delete_object, OK, RT);
|
|
|
|
|
|
|
|
else
|
|
|
|
|
|
|
|
res = pushObjects(deletedCurSeq, carddav_delete_object_by_uri, OK, RT);
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#endif // if USE_CARDDAV_MODIFY
|
|
|
|
#endif // if USE_CARDDAV_MODIFY
|
|
|
|