Commit daf13801 authored by Sebastian Kummer's avatar Sebastian Kummer

ZP-1196 Catch warnings when no GAB data can be retrieved from the

server.

Released under the Affero GNU General Public License (AGPL) version 3.
parent 33b0eb2f
......@@ -345,6 +345,10 @@ class Kopano extends SyncWorker {
PR_EC_AB_HIDDEN,
PR_DISPLAY_TYPE_EX
));
if(!is_array($gabentries)) {
$this->Log("Kopano->GetGAB(): GAB data can not be retrieved.");
return $data;
}
foreach ($gabentries as $entry) {
// do not add SYSTEM user to the GAB
if (strtoupper($entry[PR_DISPLAY_NAME]) == "SYSTEM") {
......
......@@ -128,6 +128,10 @@ abstract class SyncWorker {
$chunks[$id][$key] = $entry;
}
if (empty($chunks)) {
$this->Log("No data available");
return;
}
$entries = 0;
$minEntries = $minSize = 99999999999;
$maxEntries = $maxSize = 0;
......
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