From 0e744d49b557e3401ae7b700b1410b022a4e851c Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Mon, 28 Aug 2017 08:51:24 +0200 Subject: [PATCH] Bug 19004: [QA Follow-up] No need to check item-level_itypes again As Jonathan pointed out, GetItem already called effective_itemtype. So we can just use $item->{itype} here. Signed-off-by: Marcel de Rooy Signed-off-by: Kyle M Hall Signed-off-by: Jonathan Druart --- C4/Circulation.pm | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/C4/Circulation.pm b/C4/Circulation.pm index 34fd00d6b3..32b95c109e 100644 --- a/C4/Circulation.pm +++ b/C4/Circulation.pm @@ -1821,9 +1821,7 @@ sub AddReturn { } my $itemnumber = $item->{ itemnumber }; - my $itemtype = C4::Context->preference("item-level_itypes") - ? $item->{itype} - : Koha::Biblioitems->find( $item->{biblioitemnumber} )->itemtype; + my $itemtype = $item->{itype}; # GetItem called effective_itemtype my $issue = Koha::Checkouts->find( { itemnumber => $itemnumber } ); if ( $issue ) { -- 2.39.5