From 1c6d08a7f282f171e0a2fb969b0dbd0ea36a705f Mon Sep 17 00:00:00 2001 From: Marcel de Rooy Date: Wed, 18 Oct 2017 16:00:34 +0200 Subject: [PATCH] Bug 19484: Add test before using object itemtype MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Patch applies and functions as described. I agree with you that importing NULL itemtypes is possible Marcel. A higher importance level makes sense. Signed-off-by: Dilan Johnpullé --- svc/checkouts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/svc/checkouts b/svc/checkouts index 98251b5..e42f369 100755 --- a/svc/checkouts +++ b/svc/checkouts @@ -171,7 +171,7 @@ while ( my $c = $sth->fetchrow_hashref() ) { author => $c->{author}, barcode => $c->{barcode}, itemtype => $item_level_itypes ? $c->{itype} : $c->{itemtype}, - itemtype_description => $itemtype->translated_description, + itemtype_description => $itemtype ? $itemtype->translated_description : q{}, location => $location, homebranch => $c->{homebranch}, itemnotes => $c->{itemnotes}, -- 2.1.4