|
|
|
@ -118,6 +118,11 @@ class Hooks { |
|
|
|
|
|
|
|
|
|
if ($user->getEMailAddress() !== null) { |
|
|
|
|
$template = $this->mailer->createEMailTemplate(); |
|
|
|
|
$template->setMetaData('settings.PasswordChanged', [ |
|
|
|
|
'displayname' => $user->getDisplayName(), |
|
|
|
|
'emailAddress' => $user->getEMailAddress(), |
|
|
|
|
'instanceUrl' => $instanceUrl, |
|
|
|
|
]); |
|
|
|
|
$template->addHeader(); |
|
|
|
|
$template->addHeading($this->l->t('Password changed for %s', [$user->getDisplayName()]), false); |
|
|
|
|
$template->addBodyText($text . ' ' . $this->l->t('If you did not request this, please contact an administrator.')); |
|
|
|
@ -184,6 +189,12 @@ class Hooks { |
|
|
|
|
|
|
|
|
|
if ($oldMailAddress !== null) { |
|
|
|
|
$template = $this->mailer->createEMailTemplate(); |
|
|
|
|
$template->setMetaData('settings.EmailChanged', [ |
|
|
|
|
'displayname' => $user->getDisplayName(), |
|
|
|
|
'newEMailAddress' => $user->getEMailAddress(), |
|
|
|
|
'oldEMailAddress' => $oldMailAddress, |
|
|
|
|
'instanceUrl' => $instanceUrl, |
|
|
|
|
]); |
|
|
|
|
$template->addHeader(); |
|
|
|
|
$template->addHeading($this->l->t('Email address changed for %s', [$user->getDisplayName()]), false); |
|
|
|
|
$template->addBodyText($text . ' ' . $this->l->t('If you did not request this, please contact an administrator.')); |
|
|
|
|