diff options
author | Lukas Reschke <lukas@owncloud.com> | 2015-04-12 22:30:35 +0200 |
---|---|---|
committer | Lukas Reschke <lukas@owncloud.com> | 2015-04-12 22:30:35 +0200 |
commit | 84041a4fa26ce7a0d8cbd50aa1728ab791b7e67a (patch) | |
tree | 7292b2138cc2fefde948136de2a37b0ceca2c8a6 /core | |
parent | 907719200f844fc25ee5c5bbd93debcc9215b4a0 (diff) | |
parent | e3ad99d2523e8614b6d84765fc16104b86e9730a (diff) | |
download | nextcloud-server-84041a4fa26ce7a0d8cbd50aa1728ab791b7e67a.tar.gz nextcloud-server-84041a4fa26ce7a0d8cbd50aa1728ab791b7e67a.zip |
Merge pull request #15541 from owncloud/add-reply-to-support
Add "Reply-To" support for sharing mails as well as refactor code and add unit-tests
Diffstat (limited to 'core')
-rw-r--r-- | core/ajax/share.php | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/core/ajax/share.php b/core/ajax/share.php index bc83c41642c..d9bf97d6464 100644 --- a/core/ajax/share.php +++ b/core/ajax/share.php @@ -119,7 +119,14 @@ if (isset($_POST['action']) && isset($_POST['itemType']) && isset($_POST['itemSo // don't send a mail to the user who shared the file $recipientList = array_diff($recipientList, array(\OCP\User::getUser())); - $mailNotification = new OC\Share\MailNotifications(); + $mailNotification = new \OC\Share\MailNotifications( + \OC::$server->getUserSession()->getUser()->getUID(), + \OC::$server->getConfig(), + \OC::$server->getL10N('lib'), + \OC::$server->getMailer(), + \OC::$server->getLogger(), + $defaults + ); $result = $mailNotification->sendInternalShareMail($recipientList, $itemSource, $itemType); \OCP\Share::setSendMailStatus($itemType, $itemSource, $shareType, $recipient, true); @@ -151,7 +158,14 @@ if (isset($_POST['action']) && isset($_POST['itemType']) && isset($_POST['itemSo $file = (string)$_POST['file']; $to_address = (string)$_POST['toaddress']; - $mailNotification = new \OC\Share\MailNotifications(); + $mailNotification = new \OC\Share\MailNotifications( + \OC::$server->getUserSession()->getUser()->getUID(), + \OC::$server->getConfig(), + \OC::$server->getL10N('lib'), + \OC::$server->getMailer(), + \OC::$server->getLogger(), + $defaults + ); $expiration = null; if (isset($_POST['expiration']) && $_POST['expiration'] !== '') { |