From ad7488565b4debcc2fe17d176c86eb5d9443b160 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 Signed-off-by: Kyle M Hall --- C4/AuthoritiesMarc.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/C4/AuthoritiesMarc.pm b/C4/AuthoritiesMarc.pm index 36086dc77d..c8c59a1622 100644 --- a/C4/AuthoritiesMarc.pm +++ b/C4/AuthoritiesMarc.pm @@ -664,7 +664,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