Bug 12252: (qa-follow-up) Remove perlcritic error

Signed-off-by: Signed-off-by: Gaetan Boisson <gaetan.boisson@biblibre.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@unc.edu.ar>
This commit is contained in:
Jonathan Druart 2015-01-07 15:29:50 +01:00 committed by Tomas Cohen Arazi
parent 2fe521d11c
commit 8b24a09917

View file

@ -2943,12 +2943,13 @@ sub EmbedItemsInMarcBiblio {
require C4::Items;
while ( my ($itemnumber) = $sth->fetchrow_array ) {
next if @$itemnumbers and not grep { $_ == $itemnumber } @$itemnumbers;
my $i = C4::Items::GetItem($itemnumber) if $opachiddenitems;
my $i = $opachiddenitems ? C4::Items::GetItem($itemnumber) : undef;
push @items, { itemnumber => $itemnumber, item => $i };
}
my @hiddenitems =
C4::Items::GetHiddenItemnumbers( map { $_->{item} } @items )
if $opachiddenitems;
$opachiddenitems
? C4::Items::GetHiddenItemnumbers( map { $_->{item} } @items )
: ();
# Convert to a hash for quick searching
my %hiddenitems = map { $_ => 1 } @hiddenitems;
foreach my $itemnumber ( map { $_->{itemnumber} } @items ) {