Commit ce964911 authored by Sebastian Kummer's avatar Sebastian Kummer

ZP-783 Catch StatusException when loading conflicts.

Released under the Affero GNU General Public License (AGPL) version 3.
parent 16ad9d52
...@@ -311,6 +311,7 @@ class ImportChangesICS implements IImportChanges { ...@@ -311,6 +311,7 @@ class ImportChangesICS implements IImportChanges {
$potConflicts = $exporter->GetChangeCount(); $potConflicts = $exporter->GetChangeCount();
$started = time(); $started = time();
$exported = 0; $exported = 0;
try {
while(is_array($exporter->Synchronize())) { while(is_array($exporter->Synchronize())) {
$exported++; $exported++;
...@@ -322,6 +323,11 @@ class ImportChangesICS implements IImportChanges { ...@@ -322,6 +323,11 @@ class ImportChangesICS implements IImportChanges {
return; return;
} }
} }
}
// something really bad happened while exporting changes
catch (StatusException $stex) {
ZLog::Write(LOGLEVEL_WARN, sprintf("ImportChangesICS->lazyLoadConflicts(): got StatusException code %d while exporting changes. Ignoring and mark conflicts as loaded.",$stex->getCode()));
}
$this->conflictsLoaded = true; $this->conflictsLoaded = true;
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment