From 49fb248cfc1033e3a962dd24a2f948c03be0031a Mon Sep 17 00:00:00 2001 From: Dan Scott Date: Sun, 7 Dec 2014 08:51:33 -0500 Subject: [PATCH] LP#1400082 - avoid uninitialized var warning at TPAC login Give username a default value of '', which makes the regex happy (avoiding an uninit warning in Apache logs if no value was entered) and still counts as de nada for the purposes of the actual login dance. Signed-off-by: Dan Scott Signed-off-by: Ben Shum --- Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader.pm index 1c6f44461d..77d65056af 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader.pm @@ -364,7 +364,7 @@ sub load_login { $ctx->{page} = 'login'; - my $username = $cgi->param('username'); + my $username = $cgi->param('username') || ''; $username =~ s/\s//g; # Remove blanks my $password = $cgi->param('password'); my $org_unit = $ctx->{physical_loc} || $ctx->{aou_tree}->()->id; -- 2.11.0