From f589b2dbc53c7deaa0a40066753d95346b740be2 Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Fri, 2 Feb 2018 11:32:49 +0100 Subject: [PATCH] Bug 20126: (follow-up bug 10455) Restore MARC field length calculation in ModBiblioMarc Trivial fix. Problem raised by bug 10455. Test plan: [1] Create or edit biblio record. [2] Save and check leader field lengths in MARC view. Signed-off-by: Marcel de Rooy Signed-off-by: Jonathan Druart Signed-off-by: Nick Clemens (cherry picked from commit ef7f119b1e0c0f5403239213e9ff0f450c923acf) Signed-off-by: Fridolin Somers --- C4/Biblio.pm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/C4/Biblio.pm b/C4/Biblio.pm index 4ba09127e1..f3bbe0d9e6 100644 --- a/C4/Biblio.pm +++ b/C4/Biblio.pm @@ -3474,6 +3474,8 @@ sub ModBiblioMarc { format => 'marcxml', marcflavour => C4::Context->preference('marcflavour'), }; + $record->as_usmarc; # Bug 20126/10455 This triggers field length calculation + # FIXME To replace with ->find_or_create? if ( my $m_rs = Koha::Biblio::Metadatas->find($metadata) ) { $m_rs->metadata( $record->as_xml_record($encoding) ); -- 2.39.5