check custom field for NULL before insert it into custom field mapping

This commit is contained in:
Marc Michalsky forumZFD 2020-10-13 14:57:22 +02:00
parent 134e42240f
commit c536312185
Signed by untrusted user who does not match committer: marc.koch
GPG key ID: 12406554CFB028B9

View file

@ -230,7 +230,9 @@ class CustomField {
$customFieldMapping = []; $customFieldMapping = [];
foreach ($customFields as $customField) { foreach ($customFields as $customField) {
$customFieldMapping[$customField->getName()] = 'custom_' . $customField->getId(); if ($customField) {
$customFieldMapping[$customField->getName()] = 'custom_' . $customField->getId();
}
} }
return $customFieldMapping; return $customFieldMapping;