From 19833e4462769c98d2ce37a10975f0bc634f02c0 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 3d717adf3d..856b7dece0 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader.pm @@ -383,7 +383,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