Bug 16707: Fix software error in OPAC password recovery when leaving form fields empty
The $search_results is considered as an arrayref but is not defined if no patron matches the recovery infos. Test plan: - Set syspref OpacResetPassword to "Allow" - Go to OPAC - Click link "Forgot your password? - On the following screen "Forgotten password recovery", do not fill in form fields, click "Submit" => Without this patch you got the software error => With this patch apply, you will get "No account was found with the provided information." Sign-off on counter patch. Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
This commit is contained in:
parent
574bff5c6f
commit
0d690ca383
|
|
@ -54,7 +54,7 @@ if ( $query->param('sendEmail') || $query->param('resendEmail') ) {
|
|||
#try with the main email
|
||||
$email ||= ''; # avoid undef
|
||||
my $borrower;
|
||||
my $search_results;
|
||||
my $search_results = [];
|
||||
|
||||
# Find the borrower by his userid or email
|
||||
if ($username) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue