diff options
author | Julien Veyssier <julien-nc@posteo.net> | 2022-10-14 10:55:23 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-10-14 10:55:23 +0200 |
commit | a8101ecdb9a49dd1fd0813b627c9d58a4adfaba0 (patch) | |
tree | 6ea2a71315edfea5da0d7d414c25cf557ba55f30 /apps | |
parent | eb911d344d950ee68a023b90b799c7ab16edbd63 (diff) | |
parent | 08a77315b45821ee50a549cbe7b22e9f2c8444c0 (diff) | |
download | nextcloud-server-a8101ecdb9a49dd1fd0813b627c9d58a4adfaba0.tar.gz nextcloud-server-a8101ecdb9a49dd1fd0813b627c9d58a4adfaba0.zip |
Merge pull request #34135 from nextcloud/fix/noid/disable_activity.email_address_changed_by_admin
Fix "email changed" activity email check
Diffstat (limited to 'apps')
-rw-r--r-- | apps/settings/lib/Hooks.php | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/apps/settings/lib/Hooks.php b/apps/settings/lib/Hooks.php index b7b78c49b12..a5be30be53f 100644 --- a/apps/settings/lib/Hooks.php +++ b/apps/settings/lib/Hooks.php @@ -178,12 +178,17 @@ class Hooks { if ($actor instanceof IUser) { $subject = Provider::EMAIL_CHANGED_SELF; if ($actor->getUID() !== $user->getUID()) { + // set via the OCS API + if ($this->config->getAppValue('settings', 'disable_activity.email_address_changed_by_admin', 'no') === 'yes') { + return; + } $subject = Provider::EMAIL_CHANGED; } $text = $l->t('Your email address on %s was changed.', [$instanceUrl]); $event->setAuthor($actor->getUID()) ->setSubject($subject); } else { + // set with occ if ($this->config->getAppValue('settings', 'disable_activity.email_address_changed_by_admin', 'no') === 'yes') { return; } |