All calls to this function are either passing the framework obtained from the bib, or precede or are preceded by a bib modification which sets the framework code. We do not need this parameter in this function
Created attachment 103876 [details] [review] Bug 25306: Remove framework paramter from ModBiblioMarc
I suppose you have searched for all occurrences of ModBiblio, but why is you patch also modifying a AddBiblio call? This one: - eval { ( $biblionumber, $biblioitemnumber ) = AddBiblio( $record, '', { defer_marc_save => 1 } ) }; + eval { ( $biblionumber, $biblioitemnumber ) = AddBiblio( $record, $framework, { defer_marc_save => 1 } ) };
(In reply to Frédéric Demians from comment #2) > I suppose you have searched for all occurrences of ModBiblio, but why is you > patch also modifying a AddBiblio call? This one: > > - eval { ( $biblionumber, $biblioitemnumber ) = AddBiblio( $record, '', { > defer_marc_save => 1 } ) }; > + eval { ( $biblionumber, $biblioitemnumber ) = AddBiblio( $record, > $framework, { defer_marc_save => 1 } ) }; In that bit of code we are passing the framework to ModBiblioMarc after this call - the $framework variable is the same during both calls, moving it to the AddBiblio means we can remove it from the later call
Sorry does not apply on current master. I get : Applying: Bug 25306: Remove framework paramter from ModBiblioMarc error: sha1 information is lacking or useless (C4/Biblio.pm). error: could not build fake ancestor
Created attachment 114900 [details] [review] Bug 25306: Remove framework paramter from ModBiblioMarc
Tested with : For a framework (not the default) : Creation of a biblio record Edition of this biblio record Creation of an item of this record Creation of an item of this record ./misc/batchRepairMissingBiblionumbers.pl OK prove t/db_dependent/Biblio/ModBiblioMarc.t OK
Created attachment 114923 [details] [review] Bug 25306: Remove framework paramter from ModBiblioMarc Tested with : For a framework (not the default) : Creation of a biblio record Edition of this biblio record Creation of an item of this record Creation of an item of this record ./misc/batchRepairMissingBiblionumbers.pl OK prove t/db_dependent/Biblio/ModBiblioMarc.t OK Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Created attachment 115010 [details] [review] Bug 25306: Remove framework paramter from ModBiblioMarc Tested with : For a framework (not the default) : Creation of a biblio record Edition of this biblio record Creation of an item of this record Creation of an item of this record ./misc/batchRepairMissingBiblionumbers.pl OK prove t/db_dependent/Biblio/ModBiblioMarc.t OK Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com> Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Created attachment 115011 [details] [review] Bug 25306: (QA follow-up) Remove framework from bulkmarcimport One last instance of ModBiblioMarc in bulkmarcimport still passed the frameworkcode. Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Works as expected, tests pass and no regressions found.. I added a follow up for the final case where ModBiblioMarc was being called with a frameworkcode. Passing QA
Pushed to master for 21.05, thanks to everybody involved!
Enhancement not pushed to 20.11.x