Branch 'kolab/integration/4.13.0' - 2 commits - akonadi/tagsync.cpp

Christian Mollekopf mollekopf at kolabsys.com
Thu Jan 8 17:07:34 CET 2015


 akonadi/tagsync.cpp |   10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

New commits:
commit 33a364e3e599282d5b57febf650bead316335f14
Author: Christian Mollekopf <chrigi_1 at fastmail.fm>
Date:   Thu Jan 8 14:49:18 2015 +0100

    Don't try to modify items without remoteId (they are protected anyways).

diff --git a/akonadi/tagsync.cpp b/akonadi/tagsync.cpp
index 946e320..fae6301 100644
--- a/akonadi/tagsync.cpp
+++ b/akonadi/tagsync.cpp
@@ -200,6 +200,11 @@ void TagSync::onTagItemsFetchDone(KJob *job)
     //remove = local - remote
     Item::List toRemove;
     Q_FOREACH(const Item &local, items) {
+        //Skip items that have no remote id yet
+        //Trying to them will only result in a conflict
+        if (local.remoteId().isEmpty()) {
+            continue;
+        }
         if (!containsByGidOrRid(remoteMembers, local)) {
             toRemove << local;
         }


commit aac6bcaa2906d833ba2be26f27ec5242726def6e
Author: Christian Mollekopf <chrigi_1 at fastmail.fm>
Date:   Thu Jan 8 14:28:18 2015 +0100

    Less debug output.

diff --git a/akonadi/tagsync.cpp b/akonadi/tagsync.cpp
index 5709dc1..946e320 100644
--- a/akonadi/tagsync.cpp
+++ b/akonadi/tagsync.cpp
@@ -221,7 +221,7 @@ void TagSync::onTagItemsFetchDone(KJob *job)
     }
 }
 
-void TagSync::onJobDone(KJob *job)
+void TagSync::onJobDone(KJob *)
 {
     checkDone();
 }
@@ -229,7 +229,7 @@ void TagSync::onJobDone(KJob *job)
 void TagSync::slotResult(KJob *job)
 {
     if (job->error()) {
-        kWarning() << "Error during CollectionSync: " << job->errorString() << job->metaObject()->className();
+        kWarning() << "Error during TagSync: " << job->errorString() << job->metaObject()->className();
         // pretent there were no errors
         Akonadi::Job::removeSubjob(job);
     } else {
@@ -240,7 +240,6 @@ void TagSync::slotResult(KJob *job)
 void TagSync::checkDone()
 {
     if (hasSubjobs()) {
-        kDebug() << "Still going";
         return;
     }
     kDebug() << "done";




More information about the commits mailing list