Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/mail.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph Wurst <christoph@winzerhof-wurst.at>2020-11-16 14:28:09 +0300
committerChristoph Wurst <christoph@winzerhof-wurst.at>2020-12-01 15:43:47 +0300
commite4bcf0a515d1059192c17dae9d56b35f6c9e7769 (patch)
tree31ea63e415641f6ab09714a3a27906dc1fa854c2 /lib/AppInfo
parentb4afd1347a14559848b52ac44425b382f2e05742 (diff)
Require vendor autoloader in class definition
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
Diffstat (limited to 'lib/AppInfo')
-rw-r--r--lib/AppInfo/Application.php7
1 files changed, 2 insertions, 5 deletions
diff --git a/lib/AppInfo/Application.php b/lib/AppInfo/Application.php
index d81684cb6..886418057 100644
--- a/lib/AppInfo/Application.php
+++ b/lib/AppInfo/Application.php
@@ -24,7 +24,6 @@ declare(strict_types=1);
namespace OCA\Mail\AppInfo;
-use Exception;
use Horde_Translation;
use OCA\Mail\Contracts\IAttachmentService;
use OCA\Mail\Contracts\IAvatarService;
@@ -70,6 +69,8 @@ use OCP\User\Events\UserDeletedEvent;
use OCP\Util;
use Psr\Container\ContainerInterface;
+include_once __DIR__ . '/../../vendor/autoload.php';
+
class Application extends App implements IBootstrap {
public const APP_ID = 'mail';
@@ -78,10 +79,6 @@ class Application extends App implements IBootstrap {
}
public function register(IRegistrationContext $context): void {
- if ((@include_once __DIR__ . '/../../vendor/autoload.php') === false) {
- throw new Exception('Cannot include autoload. Did you run install dependencies using composer?');
- }
-
$context->registerParameter('hostname', Util::getServerHostName());
$context->registerService('userFolder', function (ContainerInterface $c) {