From: Andrew Moore Date: Fri, 9 May 2008 17:28:56 +0000 (-0500) Subject: Bug 2047: another fix for error during search when there is no MARC::Record X-Git-Tag: v3.00.00-stableRC1~442 X-Git-Url: http://koha-dev.rot13.org:8081/gitweb/?a=commitdiff_plain;h=c6068880ab7434cb8bf0ea18ddbe54575a3deb85;p=koha-ffzg.git Bug 2047: another fix for error during search when there is no MARC::Record This is another fix for a bug that was introduced while adding this feature. I believe that either this patch or the one at: http://lists.koha.org/pipermail/koha-patches/2008-May/000309.html should be applied. In the case that GetMarcBiblio or GetMarcStructure does not return a true value, this returns without further processing. Signed-off-by: Joshua Ferraro --- diff --git a/C4/Biblio.pm b/C4/Biblio.pm index 08c17c34b5..b6791413b1 100755 --- a/C4/Biblio.pm +++ b/C4/Biblio.pm @@ -3103,8 +3103,10 @@ sub get_biblio_authorised_values { my $authorised_values; - my $record = GetMarcBiblio( $biblionumber ); - my $tagslib = GetMarcStructure( $forlibrarian, $frameworkcode ); + my $record = GetMarcBiblio( $biblionumber ) + or return $authorised_values; + my $tagslib = GetMarcStructure( $forlibrarian, $frameworkcode ) + or return $authorised_values; # assume that these entries in the authorised_value table are bibliolevel. # ones that start with 'item%' are item level.