if ($this->logEntity->
getActivity() === ImportExportLogEntity::ACTIVITY_DRYRUN
) { $this->connection->
setNestTransactionsWithSavepoints(true
);
$this->connection->
beginTransaction();
} try { if (isset($record['_error'
]) &&
$record['_error'
] instanceof \Throwable
) { throw $record['_error'
];
} // ensure that the raw csv row has all the fields, which are marked as required by the user.
$this->
ensureUserRequiredFields($row,
$config);
$record =
$this->
ensurePrimaryKeys($record);
$event =
new ImportExportBeforeImportRecordEvent($record,
$row,
$config,
$context);
$this->eventDispatcher->
dispatch($event);
$record =
$event->
getRecord();
if ($createEntities === true &&
$updateEntities === false
) { $result =
$this->repository->
create([$record],
$context);
} elseif ($createEntities === false &&
$updateEntities === true
) {