From cd9de702e2bb9aff991e92b04d2889c91a3dcd58 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Wed, 21 Feb 2024 13:46:29 +0100 Subject: [PATCH] Bug 36170: Wrong error variable in memberentry It is hidding an important error. $@ is never set here, we need $_ (inside a try-catch) Signed-off-by: Katrin Fischer --- members/memberentry.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/members/memberentry.pl b/members/memberentry.pl index 4bc959806a..d95ff99012 100755 --- a/members/memberentry.pl +++ b/members/memberentry.pl @@ -430,7 +430,7 @@ if ((!$nok) and $nodouble and ($op eq 'cud-insert' or $op eq 'cud-save')){ } else { # FIXME Urgent error handling here, we cannot fail without relevant feedback # Lot of code will need to be removed from this script to handle exceptions raised by Koha::Patron->store - warn "Patron creation failed! - $@"; # Maybe we must die instead of just warn + warn "Patron creation failed! - $_"; # Maybe we must die instead of just warn push @messages, {error => 'error_on_insert_patron'}; } $op = "add_form"; -- 2.39.5