From e8c67c3f93feac542b93a808760acbab5244568b Mon Sep 17 00:00:00 2001 From: Colin Campbell Date: Wed, 15 Jun 2011 12:15:14 +0100 Subject: [PATCH] Bug 2505 : Switch on warnings in circ/returns.pl Removed a compile time warning caused by a void context in a bit of too clever obscure code Signed-off-by: Chris Cormack Signed-off-by: Paul Poulain (cherry picked from commit e7971380e8ff699b57d0c02b2406eca254dfd04a) Signed-off-by: Jared Camins-Esakov --- circ/returns.pl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/circ/returns.pl b/circ/returns.pl index 3b565dd785..c9f21f42fb 100755 --- a/circ/returns.pl +++ b/circ/returns.pl @@ -27,7 +27,7 @@ script to execute returns of books =cut use strict; -#use warnings; FIXME - Bug 2505 +use warnings; use CGI; use C4::Context; @@ -222,7 +222,8 @@ if ($barcode) { # ( $returned, $messages, $issueinformation, $borrower ) = AddReturn( $barcode, $userenv_branch, $exemptfine, $dropboxmode); # do the return - my $homeorholdingbranchreturn = C4::Context->preference('HomeOrHoldingBranchReturn') or 'homebranch'; + my $homeorholdingbranchreturn = C4::Context->preference('HomeOrHoldingBranchReturn'); + $homeorholdingbranchreturn ||= 'homebranch'; # get biblio description my $biblio = GetBiblioFromItemNumber($itemnumber); -- 2.39.5