Bug 24051: Remove "search( %condition ) is deprecated" warning from batchMod.pl

Test plan:
Go to Home › Tools › Batch item modification
Insert barcodes and continue
=> Without this patch you will get warning in the log
=> With this patch applied you warning does no longer appear
Confirm that the number of holds is correct

Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Joy Nelson <joy@bywatersolutions.com>
(cherry picked from commit d833b9f957)

Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
This commit is contained in:
Jonathan Druart 2019-11-18 11:29:46 +01:00 committed by Lucas Gass
parent 9020bd4bd3
commit 9bfd9e53ef
1 changed files with 1 additions and 1 deletions

View File

@ -594,7 +594,7 @@ sub BuildItemsData{
$this_row{isbn} = $biblio->biblioitem->isbn;
$this_row{biblionumber} = $biblio->biblionumber;
$this_row{holds} = $biblio->holds->count;
$this_row{item_holds} = Koha::Holds->search( itemnumber => $itemnumber )->count;
$this_row{item_holds} = Koha::Holds->search( { itemnumber => $itemnumber } )->count;
if (%this_row) {
push(@big_array, \%this_row);