Skip to content

Commit

Permalink
Syntactic sugar
Browse files Browse the repository at this point in the history
Co-authored-by: Côme Chilliet <91878298+come-nc@users.noreply.github.com>
Signed-off-by: J0WI <J0WI@users.noreply.github.com>
  • Loading branch information
J0WI and come-nc authored Dec 6, 2022
1 parent e884961 commit 5a80970
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/settings/lib/Mailer/NewUserMailHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ public function generateTemplate(IUser $user, $generatePasswordResetToken = fals
ISecureRandom::CHAR_ALPHANUMERIC
);
$tokenValue = $this->timeFactory->getTime() . ':' . $token;
$mailAddress = (null !== $user->getEMailAddress()) ? $user->getEMailAddress() : '';
$mailAddress = $user->getEMailAddress() ?? '';
$encryptedValue = $this->crypto->encrypt($tokenValue, $mailAddress . $this->config->getSystemValueString('secret'));
$this->config->setUserValue($user->getUID(), 'core', 'lostpassword', $encryptedValue);
$link = $this->urlGenerator->linkToRouteAbsolute('core.lost.resetform', ['userId' => $user->getUID(), 'token' => $token]);
Expand Down

0 comments on commit 5a80970

Please sign in to comment.