From 83a3007a33c8d2dfb1c63c8c1fbf68c2958cd1ce Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Tue, 17 Oct 2023 19:15:24 +0000 Subject: [PATCH] Bug 34014: (follow-up) No need to parse old record before updating If the old record doesn't parse correctly it will cause a failure - the check is just to ensure we are editing an existing biblio, just getting the metadata object should confirm it exists --- svc/bib | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/svc/bib b/svc/bib index 206778058b..0667c0de4b 100755 --- a/svc/bib +++ b/svc/bib @@ -89,7 +89,7 @@ sub update_bib { my $query = shift; my $biblionumber = shift; my $biblio = Koha::Biblios->find( $biblionumber ); - my $old_record = $biblio->metadata->record; + my $old_record = $biblio->metadata; my $frameworkcode = $query->url_param('frameworkcode') // GetFrameworkCode($biblionumber); unless (defined $old_record) { print $query->header(-type => 'text/xml', -status => '404 Not Found'); -- 2.30.2