Bug 30876: Fix wrong call to ->search in list context

The code is clearly incorrect as ->search no longer returns a list when
called in list context.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(cherry picked from commit 8beb878e5b)

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
This commit is contained in:
Tomas Cohen Arazi 2022-06-01 08:16:00 -03:00 committed by Lucas Gass
parent 3dcb7492ec
commit 7f8e480dfa
1 changed files with 1 additions and 1 deletions

View File

@ -71,7 +71,7 @@ if ( $op eq 'list' ) {
my @locations;
my @libraries;
my @items = Koha::Items->search({ biblio_id => $recall->biblio_id });
my @items = Koha::Items->search({ biblio_id => $recall->biblio_id })->as_list;
foreach my $item ( @items ) {
if ( $item->can_be_waiting_recall and !$item->checkout ) {
# if item can be pulled to fulfill recall, collect item data