From fe5e67265428dfe0cb2ff221cfe62da03df95038 Mon Sep 17 00:00:00 2001 From: Arthur Schiwon Date: Tue, 14 Sep 2021 23:51:48 +0200 Subject: let user choose notification email in user settings Signed-off-by: Arthur Schiwon --- apps/settings/lib/Settings/Personal/PersonalInfo.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'apps/settings/lib/Settings/Personal/PersonalInfo.php') diff --git a/apps/settings/lib/Settings/Personal/PersonalInfo.php b/apps/settings/lib/Settings/Personal/PersonalInfo.php index 0a84f20f513..d03b01b3f46 100644 --- a/apps/settings/lib/Settings/Personal/PersonalInfo.php +++ b/apps/settings/lib/Settings/Personal/PersonalInfo.php @@ -231,7 +231,7 @@ class PersonalInfo implements ISettings { * @return array */ private function getEmails(IAccount $account): array { - $primaryEmail = [ + $systemEmail = [ 'value' => $account->getProperty(IAccountManager::PROPERTY_EMAIL)->getValue(), 'scope' => $account->getProperty(IAccountManager::PROPERTY_EMAIL)->getScope(), 'verified' => $account->getProperty(IAccountManager::PROPERTY_EMAIL)->getVerified(), @@ -249,8 +249,9 @@ class PersonalInfo implements ISettings { ); $emails = [ - 'primaryEmail' => $primaryEmail, + 'primaryEmail' => $systemEmail, 'additionalEmails' => $additionalEmails, + 'notificationEmail' => (string)$account->getUser()->getPrimaryEMailAddress(), ]; return $emails; -- cgit v1.2.3