From 36b267bd0736da86aafd1059f7fca8778a5994c7 Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Mon, 26 Jun 2023 10:46:17 +0000 Subject: [PATCH] Bug 34029: (QA follow-up) Fix pushing undef to biblio_ids See comment1. Although we now fix the error on publishercode, it is good to verify the result before pushing. Signed-off-by: Marcel de Rooy Signed-off-by: Tomas Cohen Arazi (cherry picked from commit 377e2a70dec073063443c23e9b6a06f54da6b53c) Signed-off-by: Martin Renvoize (cherry picked from commit 561f6e5bd8dc5c9a671168fde67d412dbe3a0895) Signed-off-by: Pedro Amorim --- C4/ImportBatch.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/C4/ImportBatch.pm b/C4/ImportBatch.pm index 48f1e26e28..b950d193bd 100644 --- a/C4/ImportBatch.pm +++ b/C4/ImportBatch.pm @@ -617,7 +617,7 @@ sub BatchCommitRecords { if ($record_type eq 'biblio') { my $biblioitemnumber; ($recordid, $biblioitemnumber) = AddBiblio($marc_record, $framework, { skip_record_index => 1 }); - push @biblio_ids, $recordid; + push @biblio_ids, $recordid if $recordid; $query = "UPDATE import_biblios SET matched_biblionumber = ? WHERE import_record_id = ?"; # FIXME call SetMatchedBiblionumber instead if ($item_result eq 'create_new' || $item_result eq 'replace') { my ($bib_items_added, $bib_items_replaced, $bib_items_errored) = _batchCommitItems($rowref->{'import_record_id'}, $recordid, $item_result, $biblioitemnumber); -- 2.39.5