From 03049e25099dd63fab060843c106073efc79f3e1 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Fri, 16 Sep 2022 15:52:13 +0000 Subject: [PATCH] Bug 31095: (follow-up) Iterate debarments in batch mod Signed-off-by: Nick Clemens Signed-off-by: Martin Renvoize Signed-off-by: Jonathan Druart Signed-off-by: Tomas Cohen Arazi (cherry picked from commit 847d50f865c4a8b591163041fd987001ecda2ead) Signed-off-by: Matt Blenkinsop --- tools/modborrowers.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/modborrowers.pl b/tools/modborrowers.pl index 8a28815fbe..46f79d70eb 100755 --- a/tools/modborrowers.pl +++ b/tools/modborrowers.pl @@ -383,7 +383,7 @@ if ( $op eq 'do' ) { if ( grep { /debarred/ } @disabled ) { eval { my $debarrments = $patron->restrictions; - foreach my $debarment (@$debarrments) { + while( my $debarment = $debarrments->next ) { DelDebarment( $debarment->borrower_debarment_id ); } }; -- 2.39.5