From e853a25b08d0364fac7817d8c0c1fb74a39665e6 Mon Sep 17 00:00:00 2001 From: David Gustafsson Date: Mon, 26 Sep 2022 16:46:30 +0200 Subject: [PATCH] Bug 29440: Rename $modify_biblio_marc_options to $mod_bilbio_options This variable actually contains ModBibio options and ModifyBiblioMarc accepts a subset of these Signed-off-by: =?UTF-8?q?Micha=C5=82=20Kula?= <148193449+mkibp@users.noreply.github.com> --- misc/migration_tools/bulkmarcimport.pl | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/misc/migration_tools/bulkmarcimport.pl b/misc/migration_tools/bulkmarcimport.pl index 8eb0a7515a1..aaa61cd6210 100755 --- a/misc/migration_tools/bulkmarcimport.pl +++ b/misc/migration_tools/bulkmarcimport.pl @@ -124,7 +124,7 @@ if ($all) { } my $using_elastic_search = (C4::Context->preference('SearchEngine') eq 'Elasticsearch'); -my $modify_biblio_marc_options = { +my $mod_biblio_options = { disable_autolink => $using_elastic_search, defer_search_engine_indexing => $using_elastic_search, overlay_context => { source => 'bulkmarcimport' } @@ -520,7 +520,7 @@ RECORD: foreach my $record (@{$marc_records}) { }; if ($update) { my $success; - eval { $success = ModBiblio($record, $matched_record_id, GetFrameworkCode($matched_record_id), $modify_biblio_marc_options) }; + eval { $success = ModBiblio($record, $matched_record_id, GetFrameworkCode($matched_record_id), $mod_biblio_options) }; if ($@) { warn "ERROR: Update biblio $matched_record_id failed: $@\n"; printlog( { id => $matched_record_id, op => "update", status => "ERROR" } ) if ($logfile); @@ -570,7 +570,7 @@ RECORD: foreach my $record (@{$marc_records}) { C4::Biblio::_strip_item_fields($clone_record, $framework); # This sets the marc fields if there was an error, and also calls # defer_marc_save. - ModBiblioMarc($clone_record, $record_id, $modify_biblio_marc_options); + ModBiblioMarc($clone_record, $record_id, $mod_biblio_options); if ($error_adding) { warn "ERROR: Adding items to bib $record_id failed: $error_adding"; printlog({ id => $record_id, op => "insert items", status => "ERROR"}) if ($logfile); @@ -621,7 +621,7 @@ RECORD: foreach my $record (@{$marc_records}) { # @FIXME: Why do we save here without stripping items? Besides, # save with stripped items has already been performed - ModBiblioMarc($record, $record_id, $modify_biblio_marc_options); + ModBiblioMarc($record, $record_id, $mod_biblio_options); next RECORD; } else { -- 2.40.0