Bugzilla – Attachment 75264 Details for
Bug 20623
PDF export of a basket group fails when an item has an itemtype that is not in the itemtype table
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 20623: (QA follow-up) Remove one find call
Bug-20623-QA-follow-up-Remove-one-find-call.patch (text/plain), 1.49 KB, created by
Marcel de Rooy
on 2018-05-11 09:39:34 UTC
(
hide
)
Description:
Bug 20623: (QA follow-up) Remove one find call
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2018-05-11 09:39:34 UTC
Size:
1.49 KB
patch
obsolete
>From 3136347f75971602dacb5f70e822f0c81018752b Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Fri, 11 May 2018 11:33:32 +0200 >Subject: [PATCH] Bug 20623: (QA follow-up) Remove one find call >Content-Type: text/plain; charset=utf-8 > >Imo these somewhat weird lines ask for improvement, but I don't want to change >the exact conditions here. Just removing the need to call find twice. > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > acqui/basketgroup.pl | 7 +++---- > 1 file changed, 3 insertions(+), 4 deletions(-) > >diff --git a/acqui/basketgroup.pl b/acqui/basketgroup.pl >index 386357b..92a58ac 100755 >--- a/acqui/basketgroup.pl >+++ b/acqui/basketgroup.pl >@@ -194,10 +194,9 @@ sub printbasketgrouppdf{ > } > } > >- my $item_has_type_description = ($ord->{itemtype} >- and $biblioitem->itemtype >- and Koha::ItemTypes->find( $biblioitem->itemtype )); >- $ord->{itemtype} = $item_has_type_description ? Koha::ItemTypes->find( $biblioitem->itemtype )->description : undef; >+ my $itemtype = Koha::ItemTypes->find( $biblioitem->itemtype ); >+ my $item_has_type_description = $ord->{itemtype} && $biblioitem->itemtype && $itemtype; >+ $ord->{itemtype} = $item_has_type_description ? $itemtype->description : undef; > $ord->{en} = $en ? $en : undef; > $ord->{edition} = $edition ? $edition : undef; > >-- >2.1.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 20623
:
74604
|
74605
|
74913
|
75225
|
75263
| 75264 |
75273