Trim the user/email provided for password resets

Signed-off-by: Josh Richards <josh.t.richards@gmail.com>
This commit is contained in:
Josh Richards 2023-03-30 11:59:13 -04:00 committed by GitHub
parent 636c2415cc
commit 203b9131ec
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -208,7 +208,7 @@ class LostController extends Controller {
// FIXME: use HTTP error codes
try {
$this->sendEmail($user);
$this->sendEmail(trim($user));
} catch (ResetPasswordException $e) {
// Ignore the error since we do not want to leak this info
$this->logger->warning('Could not send password reset email: ' . $e->getMessage());