mirror of
https://gitlab.easter-eggs.com/ee/ldapsaisie.git
synced 2024-11-16 15:33:02 +01:00
LSioFormat: Add some checks/logs during export process
This commit is contained in:
parent
6098f3bc5f
commit
4c4983b634
1 changed files with 9 additions and 0 deletions
|
@ -131,7 +131,16 @@ class LSioFormat extends LSlog_staticLoggerClass {
|
||||||
|
|
||||||
// Add attributes to export and put their values to data to export
|
// Add attributes to export and put their values to data to export
|
||||||
foreach($fields as $key => $attr_name) {
|
foreach($fields as $key => $attr_name) {
|
||||||
|
$objects_data[$object -> getDn()][$key] = null;
|
||||||
|
if (!isset($object -> attrs[$attr_name])) {
|
||||||
|
self :: log_warning("exportObjects($object): attribute '$attr_name' does not exist !");
|
||||||
|
continue;
|
||||||
|
}
|
||||||
$object -> attrs[$attr_name] -> addToExport($export);
|
$object -> attrs[$attr_name] -> addToExport($export);
|
||||||
|
if (!isset($export -> elements[$attr_name])) {
|
||||||
|
self :: log_warning("exportObjects($object): fail to add attribute '$attr_name' to export !");
|
||||||
|
continue;
|
||||||
|
}
|
||||||
$objects_data[$object -> getDn()][$key] = $export -> elements[$attr_name] -> getApiValue(false);
|
$objects_data[$object -> getDn()][$key] = $export -> elements[$attr_name] -> getApiValue(false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue