Skip to content

Commit

Permalink
set default mapping value to null
Browse files Browse the repository at this point in the history
  • Loading branch information
Gyvastis committed Sep 9, 2021
1 parent ce8b4dc commit 1818145
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/Mapper.php
Original file line number Diff line number Diff line change
Expand Up @@ -410,9 +410,7 @@ public function mapToSalesforceObject($model)
$allMappings = $mappedProperties->toArray() + $mappedRelations;

foreach ($allMappings as $property => $mapping) {
if(isset($value)) {
unset($value);
}
$value = null;
if ($mapping instanceof Annotation\Field) {
$fieldDescription = $objectDescription->getField($mapping->name);
$fieldName = $mapping->name;
Expand Down

0 comments on commit 1818145

Please sign in to comment.