From b3c42f8331d6c83b505040c2f711cb0e577ecba7 Mon Sep 17 00:00:00 2001 From: Aleisha Amohia Date: Mon, 2 May 2022 16:56:37 +1200 Subject: [PATCH] Bug 30358: (follow-up) Put multiple subfields fix on auth side Signed-off-by: David Nind --- C4/AuthoritiesMarc.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/C4/AuthoritiesMarc.pm b/C4/AuthoritiesMarc.pm index 5ab93c7d32..a9587a1950 100644 --- a/C4/AuthoritiesMarc.pm +++ b/C4/AuthoritiesMarc.pm @@ -648,7 +648,8 @@ sub AddAuthority { my $value = $subfield->[1]; $value =~ s/[\n\r]+/ /g; $value =~ s/^\s+|\s+$|^\t+|\t+$//g; - $field->update( $key => $value ); + $field->add_subfields( $key => $value ); # add subfield to the end of the subfield list + $field->delete_subfield( pos => 0 ); # delete the subfield at the top of the subfield list } } } -- 2.30.2