Sync: fix issues with PHP 5.3

Problem has been introduced with f885d90

fixes 
This commit is contained in:
Thomas Gelf 2017-04-26 15:31:24 +02:00
parent a63135be2a
commit 6de258730b
2 changed files with 8 additions and 2 deletions
library/Director/Import

View File

@ -268,8 +268,10 @@ class Sync
$filterColumns[$column] = $column;
}
}
foreach (SyncUtils::getRootVariables($filterColumns) as $column) {
$usedColumns[$column] = $column;
if (! empty($filterColumns)) {
foreach (SyncUtils::getRootVariables($filterColumns) as $column) {
$usedColumns[$column] = $column;
}
}
$rows = $run->fetchRows($usedColumns);

View File

@ -125,6 +125,10 @@ class SyncUtils
}
}
if (empty($res)) {
return array();
}
return array_combine($res, $res);
}
}