From 36e2456253695f3bceef530ba39cc7acb515b4dc Mon Sep 17 00:00:00 2001 From: =?utf8?q?Joonas=20Kylm=C3=A4l=C3=A4?= Date: Sun, 31 Oct 2021 12:22:06 +0000 Subject: [PATCH] Bug 29283: (QA follow-up) Remove code duplication MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit We have already a search filter for active orders. Signed-off-by: Joonas Kylmälä Signed-off-by: Jonathan Druart Signed-off-by: Kyle M Hall (cherry picked from commit 396a256ae50ada5e2874f4ad5a59cb5ff85722ed) Signed-off-by: Fridolin Somers --- acqui/basket.pl | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/acqui/basket.pl b/acqui/basket.pl index 19a580bd08..65eb62e04b 100755 --- a/acqui/basket.pl +++ b/acqui/basket.pl @@ -132,9 +132,7 @@ if ( $op eq 'delete_confirm' ) { my $delbiblio = $query->param('delbiblio'); my $basket_obj = Koha::Acquisition::Baskets->find($basketno); - my $orders = $basket_obj->orders->search({ - datecancellationprinted => undef - }); + my $orders = $basket_obj->orders->filter_by_current; my @cannotdelbiblios; -- 2.39.5