This commit is contained in:
James Cole 2017-12-13 17:09:55 +01:00
parent 044af254f3
commit 9264f1e9b9
No known key found for this signature in database
GPG Key ID: C16961E655E74B5E

View File

@ -80,6 +80,7 @@ class CsvProcessor implements FileProcessorInterface
Log::debug(sprintf('Number of entries: %d', $entries->count()));
$notImported = $entries->filter(
function (array $row, int $index) {
$row = array_values($row);
if ($this->rowAlreadyImported($row)) {
$message = sprintf('Row #%d has already been imported.', $index);
$this->job->addError($index, $message);
@ -241,6 +242,7 @@ class CsvProcessor implements FileProcessorInterface
*/
private function importRow(int $index, array $row): ImportJournal
{
$row = array_values($row);
Log::debug(sprintf('Now at row %d', $index));
$row = $this->specifics($row);
$hash = $this->getRowHash($row);