summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorRoeland Jago Douma <rullzer@users.noreply.github.com>2017-04-21 09:35:01 +0200
committerGitHub <noreply@github.com>2017-04-21 09:35:01 +0200
commite9b00f84b85e97283b83cf951f9bd262e627ae9a (patch)
treebcc89a56e67397461a1afd54e0836315fd06e08a /lib
parentc4bd01456b7fc8e531af1e8cc37dbff4f1ca8578 (diff)
parent73b6cd1061480078ec252c1e5e1d97ac48ea892a (diff)
downloadnextcloud-server-e9b00f84b85e97283b83cf951f9bd262e627ae9a.tar.gz
nextcloud-server-e9b00f84b85e97283b83cf951f9bd262e627ae9a.zip
Merge pull request #4406 from nextcloud/fix-unit-test-problems
Fix unit test problems
Diffstat (limited to 'lib')
-rw-r--r--lib/composer/composer/autoload_classmap.php1
-rw-r--r--lib/composer/composer/autoload_static.php1
-rw-r--r--lib/private/Share/MailNotifications.php89
-rw-r--r--lib/public/Defaults.php2
4 files changed, 1 insertions, 92 deletions
diff --git a/lib/composer/composer/autoload_classmap.php b/lib/composer/composer/autoload_classmap.php
index 823a876e04b..0d5f067779d 100644
--- a/lib/composer/composer/autoload_classmap.php
+++ b/lib/composer/composer/autoload_classmap.php
@@ -808,7 +808,6 @@ return array(
'OC\\Share20\\ShareHelper' => $baseDir . '/lib/private/Share20/ShareHelper.php',
'OC\\Share\\Constants' => $baseDir . '/lib/private/Share/Constants.php',
'OC\\Share\\Helper' => $baseDir . '/lib/private/Share/Helper.php',
- 'OC\\Share\\MailNotifications' => $baseDir . '/lib/private/Share/MailNotifications.php',
'OC\\Share\\SearchResultSorter' => $baseDir . '/lib/private/Share/SearchResultSorter.php',
'OC\\Share\\Share' => $baseDir . '/lib/private/Share/Share.php',
'OC\\Streamer' => $baseDir . '/lib/private/Streamer.php',
diff --git a/lib/composer/composer/autoload_static.php b/lib/composer/composer/autoload_static.php
index 979679c4198..82c31c24a21 100644
--- a/lib/composer/composer/autoload_static.php
+++ b/lib/composer/composer/autoload_static.php
@@ -838,7 +838,6 @@ class ComposerStaticInit53792487c5a8370acc0b06b1a864ff4c
'OC\\Share20\\ShareHelper' => __DIR__ . '/../../..' . '/lib/private/Share20/ShareHelper.php',
'OC\\Share\\Constants' => __DIR__ . '/../../..' . '/lib/private/Share/Constants.php',
'OC\\Share\\Helper' => __DIR__ . '/../../..' . '/lib/private/Share/Helper.php',
- 'OC\\Share\\MailNotifications' => __DIR__ . '/../../..' . '/lib/private/Share/MailNotifications.php',
'OC\\Share\\SearchResultSorter' => __DIR__ . '/../../..' . '/lib/private/Share/SearchResultSorter.php',
'OC\\Share\\Share' => __DIR__ . '/../../..' . '/lib/private/Share/Share.php',
'OC\\Streamer' => __DIR__ . '/../../..' . '/lib/private/Streamer.php',
diff --git a/lib/private/Share/MailNotifications.php b/lib/private/Share/MailNotifications.php
deleted file mode 100644
index e10389e77b9..00000000000
--- a/lib/private/Share/MailNotifications.php
+++ /dev/null
@@ -1,89 +0,0 @@
-<?php
-/**
- * @copyright Copyright (c) 2016, ownCloud, Inc.
- *
- * @author Björn Schießle <bjoern@schiessle.org>
- * @author Joas Schilling <coding@schilljs.com>
- * @author Lukas Reschke <lukas@statuscode.ch>
- * @author Morris Jobke <hey@morrisjobke.de>
- * @author Robin McCorkell <robin@mccorkell.me.uk>
- * @author Roeland Jago Douma <roeland@famdouma.nl>
- * @author scolebrook <scolebrook@mac.com>
- * @author Thomas Müller <thomas.mueller@tmit.eu>
- * @author Vincent Petry <pvince81@owncloud.com>
- *
- * @license AGPL-3.0
- *
- * This code is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Affero General Public License, version 3,
- * as published by the Free Software Foundation.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Affero General Public License for more details.
- *
- * You should have received a copy of the GNU Affero General Public License, version 3,
- * along with this program. If not, see <http://www.gnu.org/licenses/>
- *
- */
-
-namespace OC\Share;
-
-use OCP\IL10N;
-use OCP\IURLGenerator;
-use OCP\IUser;
-use OCP\Mail\IMailer;
-use OCP\ILogger;
-use OCP\Defaults;
-use OCP\Util;
-
-/**
- * Class MailNotifications
- *
- * @package OC\Share
- */
-class MailNotifications {
-
- /** @var IUser sender userId */
- private $user;
- /** @var string sender email address */
- private $replyTo;
- /** @var string */
- private $senderDisplayName;
- /** @var IL10N */
- private $l;
- /** @var IMailer */
- private $mailer;
- /** @var Defaults */
- private $defaults;
- /** @var ILogger */
- private $logger;
- /** @var IURLGenerator */
- private $urlGenerator;
-
- /**
- * @param IUser $user
- * @param IL10N $l10n
- * @param IMailer $mailer
- * @param ILogger $logger
- * @param Defaults $defaults
- * @param IURLGenerator $urlGenerator
- */
- public function __construct(IUser $user,
- IL10N $l10n,
- IMailer $mailer,
- ILogger $logger,
- Defaults $defaults,
- IURLGenerator $urlGenerator) {
- $this->l = $l10n;
- $this->user = $user;
- $this->mailer = $mailer;
- $this->logger = $logger;
- $this->defaults = $defaults;
- $this->urlGenerator = $urlGenerator;
-
- $this->replyTo = $this->user->getEMailAddress();
- $this->senderDisplayName = $this->user->getDisplayName();
- }
-}
diff --git a/lib/public/Defaults.php b/lib/public/Defaults.php
index 591da18c7ee..dbde78bce68 100644
--- a/lib/public/Defaults.php
+++ b/lib/public/Defaults.php
@@ -51,7 +51,7 @@ class Defaults {
* actual defaults
* @since 6.0.0
*/
- function __construct(\OC_Defaults $defaults = null) {
+ public function __construct(\OC_Defaults $defaults = null) {
if ($defaults === null) {
$defaults = \OC::$server->getThemingDefaults();
}