From 89c4bc43e5fabe3f116bf1d28b16ba58ffbeb1b2 Mon Sep 17 00:00:00 2001 From: Galen Charlton Date: Wed, 22 Jul 2009 09:06:06 -0500 Subject: [PATCH] followup to AddReturn patch - fix test Signed-off-by: Galen Charlton --- C4/Circulation.pm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/C4/Circulation.pm b/C4/Circulation.pm index f27ea3e051..f489fa8a3a 100644 --- a/C4/Circulation.pm +++ b/C4/Circulation.pm @@ -1335,11 +1335,12 @@ sub AddReturn { $messages->{'BadBarcode'} = $barcode; $doreturn = 0; } else { - if ( not $iteminformation ) { + if ( not %$iteminformation ) { $messages->{'NotIssued'} = $barcode; # even though item is not on loan, it may still # be transferred; therefore, get current branch information - my $curr_iteminfo = GetItem($iteminformation->{'itemnumber'}); + my $curr_iteminfo = GetItem($itemnumber); + $iteminformation->{'itemnumber'} = $curr_iteminfo->{'itemnumber'}; $iteminformation->{'homebranch'} = $curr_iteminfo->{'homebranch'}; $iteminformation->{'holdingbranch'} = $curr_iteminfo->{'holdingbranch'}; $iteminformation->{'itemlost'} = $curr_iteminfo->{'itemlost'}; -- 2.39.5