aboutsummaryrefslogtreecommitdiffstats
path: root/apps/files_external/lib/AppInfo/Application.php
diff options
context:
space:
mode:
Diffstat (limited to 'apps/files_external/lib/AppInfo/Application.php')
-rw-r--r--apps/files_external/lib/AppInfo/Application.php16
1 files changed, 7 insertions, 9 deletions
diff --git a/apps/files_external/lib/AppInfo/Application.php b/apps/files_external/lib/AppInfo/Application.php
index fc4f012cd02..a6c2aff947b 100644
--- a/apps/files_external/lib/AppInfo/Application.php
+++ b/apps/files_external/lib/AppInfo/Application.php
@@ -1,4 +1,5 @@
<?php
+
/**
* SPDX-FileCopyrightText: 2016-2024 Nextcloud GmbH and Nextcloud contributors
* SPDX-FileCopyrightText: 2016 ownCloud, Inc.
@@ -9,10 +10,10 @@ namespace OCA\Files_External\AppInfo;
use OCA\Files\Event\LoadAdditionalScriptsEvent;
use OCA\Files_External\Config\ConfigAdapter;
use OCA\Files_External\Config\UserPlaceholderHandler;
+use OCA\Files_External\ConfigLexicon;
use OCA\Files_External\Lib\Auth\AmazonS3\AccessKey;
use OCA\Files_External\Lib\Auth\Builtin;
use OCA\Files_External\Lib\Auth\NullMechanism;
-use OCA\Files_External\Lib\Auth\OAuth1\OAuth1;
use OCA\Files_External\Lib\Auth\OAuth2\OAuth2;
use OCA\Files_External\Lib\Auth\OpenStack\OpenStackV2;
use OCA\Files_External\Lib\Auth\OpenStack\OpenStackV3;
@@ -47,12 +48,11 @@ use OCP\AppFramework\App;
use OCP\AppFramework\Bootstrap\IBootContext;
use OCP\AppFramework\Bootstrap\IBootstrap;
use OCP\AppFramework\Bootstrap\IRegistrationContext;
+use OCP\AppFramework\QueryException;
use OCP\Files\Config\IMountProviderCollection;
use OCP\Group\Events\GroupDeletedEvent;
use OCP\User\Events\UserDeletedEvent;
-require_once __DIR__ . '/../../3rdparty/autoload.php';
-
/**
* @package OCA\Files_External\AppInfo
*/
@@ -62,7 +62,7 @@ class Application extends App implements IBackendProvider, IAuthMechanismProvide
/**
* Application constructor.
*
- * @throws \OCP\AppFramework\QueryException
+ * @throws QueryException
*/
public function __construct(array $urlParams = []) {
parent::__construct(self::APP_ID, $urlParams);
@@ -72,13 +72,14 @@ class Application extends App implements IBackendProvider, IAuthMechanismProvide
$context->registerEventListener(UserDeletedEvent::class, UserDeletedListener::class);
$context->registerEventListener(GroupDeletedEvent::class, GroupDeletedListener::class);
$context->registerEventListener(LoadAdditionalScriptsEvent::class, LoadAdditionalListener::class);
+ $context->registerConfigLexicon(ConfigLexicon::class);
}
public function boot(IBootContext $context): void {
- $context->injectFn(function (IMountProviderCollection $mountProviderCollection, ConfigAdapter $configAdapter) {
+ $context->injectFn(function (IMountProviderCollection $mountProviderCollection, ConfigAdapter $configAdapter): void {
$mountProviderCollection->registerProvider($configAdapter);
});
- $context->injectFn(function (BackendService $backendService, UserPlaceholderHandler $userConfigHandler) {
+ $context->injectFn(function (BackendService $backendService, UserPlaceholderHandler $userConfigHandler): void {
$backendService->registerBackendProvider($this);
$backendService->registerAuthMechanismProvider($this);
$backendService->registerConfigHandler('user', function () use ($userConfigHandler) {
@@ -134,9 +135,6 @@ class Application extends App implements IBackendProvider, IAuthMechanismProvide
$container->get(GlobalAuth::class),
$container->get(UserGlobalAuth::class),
- // AuthMechanism::SCHEME_OAUTH1 mechanisms
- $container->get(OAuth1::class),
-
// AuthMechanism::SCHEME_OAUTH2 mechanisms
$container->get(OAuth2::class),