From: Colin Campbell Date: Wed, 15 Jun 2011 11:15:14 +0000 (+0100) Subject: Bug 2505 : Switch on warnings in circ/returns.pl X-Git-Tag: v3.08.00~82 X-Git-Url: http://koha-dev.rot13.org:8081/gitweb/?a=commitdiff_plain;h=e7971380e8ff699b57d0c02b2406eca254dfd04a;p=koha_fer 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 --- diff --git a/circ/returns.pl b/circ/returns.pl index 83817a8310..bd60d42978 100755 --- a/circ/returns.pl +++ b/circ/returns.pl @@ -28,7 +28,7 @@ script to execute returns of books =cut use strict; -#use warnings; FIXME - Bug 2505 +use warnings; use CGI; use DateTime; @@ -223,7 +223,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);