]> source.dussan.org Git - nextcloud-server.git/commitdiff
fix some types
authorRobin Appelman <robin@icewind.nl>
Fri, 26 Mar 2021 14:51:07 +0000 (15:51 +0100)
committerArthur Schiwon <blizzz@arthur-schiwon.de>
Wed, 16 Jun 2021 11:56:26 +0000 (13:56 +0200)
Signed-off-by: Robin Appelman <robin@icewind.nl>
apps/files_external/lib/AppInfo/Application.php
apps/files_external/lib/Command/Create.php
apps/files_external/lib/Command/Import.php

index 2181a7e2533818f0290efb3502bfa3e19be36b65..b303ff5539c5723648c5a0f60c0c30afe5468e68 100644 (file)
@@ -33,7 +33,6 @@ use OCA\Files_External\Config\ConfigAdapter;
 use OCA\Files_External\Config\UserPlaceholderHandler;
 use OCA\Files_External\Listener\GroupDeletedListener;
 use OCA\Files_External\Listener\UserDeletedListener;
-use OCA\Files_External\Service\DBConfigService;
 use OCA\Files_External\Lib\Auth\AmazonS3\AccessKey;
 use OCA\Files_External\Lib\Auth\Builtin;
 use OCA\Files_External\Lib\Auth\NullMechanism;
@@ -70,12 +69,7 @@ use OCP\AppFramework\Bootstrap\IBootstrap;
 use OCP\AppFramework\Bootstrap\IRegistrationContext;
 use OCP\Files\Config\IMountProviderCollection;
 use OCP\Group\Events\GroupDeletedEvent;
-use OCP\IGroup;
-use OCP\IUser;
 use OCP\User\Events\UserDeletedEvent;
-use Symfony\Component\EventDispatcher\EventDispatcherInterface;
-use Symfony\Component\EventDispatcher\GenericEvent;
-use function foo\func;
 
 require_once __DIR__ . '/../../3rdparty/autoload.php';
 
@@ -112,7 +106,7 @@ class Application extends App implements IBackendProvider, IAuthMechanismProvide
                                'name' => $l->t('External storages'),
                        ];
                });
-               $context->injectFn(function(BackendService $backendService, UserPlaceholderHandler $userConfigHandler) {
+               $context->injectFn(function (BackendService $backendService, UserPlaceholderHandler $userConfigHandler) {
                        $backendService->registerBackendProvider($this);
                        $backendService->registerAuthMechanismProvider($this);
                        $backendService->registerConfigHandler('user', function () use ($userConfigHandler) {
index 3fe9e71b17a1eab58c53912f584f2ee892f51491..99991b893cdab53dc122166622c5789bfbe31de0 100644 (file)
@@ -119,7 +119,7 @@ class Create extends Base {
        }
 
        protected function execute(InputInterface $input, OutputInterface $output): int {
-               $user = $input->getOption('user');
+               $user = (string) $input->getOption('user');
                $mountPoint = $input->getArgument('mount_point');
                $storageIdentifier = $input->getArgument('storage_backend');
                $authIdentifier = $input->getArgument('authentication_backend');
index 5d9a6893353b7a07517dc5552dc6bcb71fb2fd4a..53ae0d7c5bf88a00232d15d91346b5cc45882af2 100644 (file)
@@ -107,7 +107,7 @@ class Import extends Base {
        }
 
        protected function execute(InputInterface $input, OutputInterface $output): int {
-               $user = $input->getOption('user');
+               $user = (string) $input->getOption('user');
                $path = $input->getArgument('path');
                if ($path === '-') {
                        $json = file_get_contents('php://stdin');