aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorBjoern Schiessle <bjoern@schiessle.org>2016-11-02 11:37:25 +0100
committerBjoern Schiessle <bjoern@schiessle.org>2016-11-02 18:30:38 +0100
commitf556c58c22405945263bc6debfa6a424e2c601cb (patch)
tree648f879e3f46214bd8e0c36f9d8b7b0971d9cbdb /apps
parent7da3ba3f91f561da664fc601b29cd7948f876f3f (diff)
downloadnextcloud-server-f556c58c22405945263bc6debfa6a424e2c601cb.tar.gz
nextcloud-server-f556c58c22405945263bc6debfa6a424e2c601cb.zip
remove 'send mail notification' option from sharing, replaced by send-by-mail feature
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
Diffstat (limited to 'apps')
-rw-r--r--apps/files/lib/Controller/ViewController.php2
-rw-r--r--apps/files/templates/index.php2
-rw-r--r--apps/files/tests/Controller/ViewControllerTest.php2
-rw-r--r--apps/files_sharing/lib/Capabilities.php4
-rw-r--r--apps/files_sharing/tests/CapabilitiesTest.php18
5 files changed, 2 insertions, 26 deletions
diff --git a/apps/files/lib/Controller/ViewController.php b/apps/files/lib/Controller/ViewController.php
index d3708915273..6f74fec861f 100644
--- a/apps/files/lib/Controller/ViewController.php
+++ b/apps/files/lib/Controller/ViewController.php
@@ -235,8 +235,6 @@ class ViewController extends Controller {
$params['owner'] = $storageInfo['owner'];
$params['ownerDisplayName'] = $storageInfo['ownerDisplayName'];
$params['isPublic'] = false;
- $params['mailNotificationEnabled'] = $this->config->getAppValue('core', 'shareapi_allow_mail_notification', 'no');
- $params['mailPublicNotificationEnabled'] = $this->config->getAppValue('core', 'shareapi_allow_public_notification', 'no');
$params['allowShareWithLink'] = $this->config->getAppValue('core', 'shareapi_allow_links', 'yes');
$user = $this->userSession->getUser()->getUID();
$params['defaultFileSorting'] = $this->config->getUserValue($user, 'files', 'file_sorting', 'name');
diff --git a/apps/files/templates/index.php b/apps/files/templates/index.php
index 17958d330b7..1670ccfd138 100644
--- a/apps/files/templates/index.php
+++ b/apps/files/templates/index.php
@@ -16,8 +16,6 @@
<input type="hidden" name="ownerDisplayName" id="ownerDisplayName" value="<?php p($_['ownerDisplayName']); ?>" />
<input type="hidden" name="fileNotFound" id="fileNotFound" value="<?php p($_['fileNotFound']); ?>" />
<?php if (!$_['isPublic']) :?>
-<input type="hidden" name="mailNotificationEnabled" id="mailNotificationEnabled" value="<?php p($_['mailNotificationEnabled']) ?>" />
-<input type="hidden" name="mailPublicNotificationEnabled" id="mailPublicNotificationEnabled" value="<?php p($_['mailPublicNotificationEnabled']) ?>" />
<input type="hidden" name="allowShareWithLink" id="allowShareWithLink" value="<?php p($_['allowShareWithLink']) ?>" />
<input type="hidden" name="defaultFileSorting" id="defaultFileSorting" value="<?php p($_['defaultFileSorting']) ?>" />
<input type="hidden" name="defaultFileSortingDirection" id="defaultFileSortingDirection" value="<?php p($_['defaultFileSortingDirection']) ?>" />
diff --git a/apps/files/tests/Controller/ViewControllerTest.php b/apps/files/tests/Controller/ViewControllerTest.php
index 179aaa373b3..25445567ea9 100644
--- a/apps/files/tests/Controller/ViewControllerTest.php
+++ b/apps/files/tests/Controller/ViewControllerTest.php
@@ -218,8 +218,6 @@ class ViewControllerTest extends TestCase {
'defaultFileSortingDirection' => 'asc',
'showHiddenFiles' => 0,
'fileNotFound' => 0,
- 'mailNotificationEnabled' => 'no',
- 'mailPublicNotificationEnabled' => 'no',
'allowShareWithLink' => 'yes',
'appNavigation' => $nav,
'appContents' => [
diff --git a/apps/files_sharing/lib/Capabilities.php b/apps/files_sharing/lib/Capabilities.php
index 9da6dbbc995..bfbd15c1122 100644
--- a/apps/files_sharing/lib/Capabilities.php
+++ b/apps/files_sharing/lib/Capabilities.php
@@ -73,10 +73,10 @@ class Capabilities implements ICapability {
}
$res["public"] = $public;
- $res['user']['send_mail'] = $this->config->getAppValue('core', 'shareapi_allow_mail_notification', 'no') === 'yes';
-
$res['resharing'] = $this->config->getAppValue('core', 'shareapi_allow_resharing', 'yes') === 'yes';
+ $res['user']['send_mail'] = false;
+
$res['group_sharing'] = $this->config->getAppValue('core', 'shareapi_allow_group_sharing', 'yes') === 'yes';
}
diff --git a/apps/files_sharing/tests/CapabilitiesTest.php b/apps/files_sharing/tests/CapabilitiesTest.php
index 254f7cdaa7c..3d59b1f6f34 100644
--- a/apps/files_sharing/tests/CapabilitiesTest.php
+++ b/apps/files_sharing/tests/CapabilitiesTest.php
@@ -188,24 +188,6 @@ class CapabilitiesTest extends \Test\TestCase {
$this->assertFalse($result['public']['send_mail']);
}
- public function testUserSendMail() {
- $map = [
- ['core', 'shareapi_enabled', 'yes', 'yes'],
- ['core', 'shareapi_allow_mail_notification', 'no', 'yes'],
- ];
- $result = $this->getResults($map);
- $this->assertTrue($result['user']['send_mail']);
- }
-
- public function testUserNoSendMail() {
- $map = [
- ['core', 'shareapi_enabled', 'yes', 'yes'],
- ['core', 'shareapi_allow_mail_notification', 'no', 'no'],
- ];
- $result = $this->getResults($map);
- $this->assertFalse($result['user']['send_mail']);
- }
-
public function testResharing() {
$map = [
['core', 'shareapi_enabled', 'yes', 'yes'],