From: Chris Sharp Date: Mon, 29 Aug 2022 16:45:16 +0000 (-0400) Subject: declare the variable once, then update the values X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=1b4f70d11baa65a8eb026b2744c33e5e6bd503b6;p=evergreen%2Fpines.git declare the variable once, then update the values Signed-off-by: Chris Sharp --- diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Ecard.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Ecard.pm index 69db0767a3..a230855f02 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Ecard.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Ecard.pm @@ -20,14 +20,15 @@ my $U = 'OpenILS::Application::AppUtils'; my $self = shift; my $path = $self->apache->path_info; my $update_type = 'register'; +my @api_fields; if ($path =~ m|opac/erenew/submit|) { - my $update_type = 'renew'; + $update_type = 'renew'; } # Create different api_fields array if registration or renewal if ($update_type == 'renew') { - my @api_fields = ( + @api_fields = ( {name => 'vendor_username', required => 1}, {name => 'vendor_password', required => 1}, {name => 'patron_id', required => 1}, #needed for matching @@ -57,7 +58,7 @@ if ($update_type == 'renew') { {name => 'temp_renewal'} #new boolean value ); } else { - my @api_fields = ( + @api_fields = ( {name => 'vendor_username', required => 1}, {name => 'vendor_password', required => 1}, {name => 'first_given_name', class => 'au', required => 1},