diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref
index bb9e1eb905..b4ea23ceeb 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref
@@ -346,13 +346,13 @@ OPAC:
no: "Don't allow"
- patrons to change their own password on the OPAC. Note that this must be off to use LDAP authentication.
-
- - "The user "
+ - "Library users are "
- pref: OpacResetPassword
default: 1
choices:
- yes: "can reset"
- no: "can not reset"
- - " their password on OPAC."
+ yes: "allowed"
+ no: "not allowed"
+ - " to recover their password via e-mail in the OPAC"
-
- pref: OPACPatronDetails
choices:
diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc b/koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc
index 636c5cbd06..21504c215f 100644
--- a/koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc
+++ b/koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc
@@ -318,8 +318,7 @@
[% IF Koha.Preference('OpacPasswordChange') && Koha.Preference('OpacResetPassword') %]
-
Forgot your password?
-
If you do not remember your password, click here to create a new one.
[% END %]
[% IF Koha.Preference( 'NoLoginInstructions' ) %]
diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-password-recovery.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-password-recovery.tt
index 8eedb7d0d4..8ffb3e3945 100644
--- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-password-recovery.tt
+++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-password-recovery.tt
@@ -1,6 +1,6 @@
[% USE Koha %]
[% INCLUDE 'doc-head-open.inc' %]
-[% IF (LibraryNameTitle) %][% LibraryNameTitle %][% ELSE %]Koha online[% END %] catalog ›
+[% IF ( LibraryNameTitle ) %][% LibraryNameTitle %][% ELSE %]Koha online[% END %] catalog
[% INCLUDE 'doc-head-close.inc' %]
[% BLOCK cssinclude %][% END %]
[% BLOCK jsinclude %]
@@ -36,18 +36,21 @@
+ [% IF ( OpacPublic ) %]
+
[% INCLUDE 'navigation.inc' IsPatronPage=0 %]
+ [% END %]
Password recovery
[% IF (hasError) %]
-
An error occured
+
An error occurred
[% IF (sendmailError) %]
- An error has occured while sending you the password recovery link.
+ An error has occurred while sending you the password recovery link.
Please try again later.
[% ELSIF (errNoBorrowerFound) %]
No account was found with the provided information.
@@ -131,4 +134,4 @@
-[% INCLUDE 'opac-bottom.inc' %]
\ No newline at end of file
+[% INCLUDE 'opac-bottom.inc' %]
diff --git a/opac/opac-password-recovery.pl b/opac/opac-password-recovery.pl
index 0013870f99..e2cd74e665 100755
--- a/opac/opac-password-recovery.pl
+++ b/opac/opac-password-recovery.pl
@@ -54,7 +54,6 @@ if ( $query->param('sendEmail') || $query->param('resendEmail') ) {
$email ||= ''; # avoid undef
my $borrower;
my $search_results;
-
# Find the borrower by his userid or email
if( $username ){
$search_results = Search({ userid => $username });
@@ -62,8 +61,11 @@ if ( $query->param('sendEmail') || $query->param('resendEmail') ) {
elsif ( $email ){
$search_results = Search({ '' => $email }, undef, undef, undef, ['emailpro', 'email', 'B_email']);
}
-
- if(scalar @$search_results > 1){ # Many matching borrowers
+ if ( not $search_results ){
+ $hasError = 1;
+ $errNoBorrowerFound = 1;
+ }
+ elsif(scalar @$search_results > 1){ # Many matching borrowers
$hasError = 1;
$errTooManyEmailFound = 1;
}
@@ -112,7 +114,7 @@ if ( $query->param('sendEmail') || $query->param('resendEmail') ) {
email => $email
);
}
- else {# if it doesnt work....
+ else {# if it doesn't work....
$template->param(
password_recovery => 1,
sendmailError => 1