diff options
Diffstat (limited to 'apps/files_external/lib/Command/Create.php')
-rw-r--r-- | apps/files_external/lib/Command/Create.php | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/apps/files_external/lib/Command/Create.php b/apps/files_external/lib/Command/Create.php index 372fa4ef372..17e4731a2d6 100644 --- a/apps/files_external/lib/Command/Create.php +++ b/apps/files_external/lib/Command/Create.php @@ -34,6 +34,7 @@ use OCA\Files_External\Lib\StorageConfig; use OCA\Files_External\Service\BackendService; use OCA\Files_External\Service\GlobalStoragesService; use OCA\Files_External\Service\UserStoragesService; +use OCA\Files_External\Service\StoragesService; use OCP\IUserManager; use OCP\IUserSession; use Symfony\Component\Console\Input\ArrayInput; @@ -104,7 +105,7 @@ class Create extends Base { } protected function execute(InputInterface $input, OutputInterface $output): int { - $user = (string) $input->getOption('user'); + $user = (string)$input->getOption('user'); $mountPoint = $input->getArgument('mount_point'); $storageIdentifier = $input->getArgument('storage_backend'); $authIdentifier = $input->getArgument('authentication_backend'); @@ -172,7 +173,7 @@ class Create extends Base { return 0; } - private function validateParam($key, &$value, Backend $storageBackend, AuthMechanism $authBackend): bool { + private function validateParam(string $key, &$value, Backend $storageBackend, AuthMechanism $authBackend): bool { $params = array_merge($storageBackend->getParameters(), $authBackend->getParameters()); foreach ($params as $param) { /** @var DefinitionParameter $param */ @@ -186,7 +187,7 @@ class Create extends Base { return false; } - private function showMount($user, StorageConfig $mount, InputInterface $input, OutputInterface $output): void { + private function showMount(string $user, StorageConfig $mount, InputInterface $input, OutputInterface $output): void { $listCommand = new ListCommand($this->globalService, $this->userService, $this->userSession, $this->userManager); $listInput = new ArrayInput([], $listCommand->getDefinition()); $listInput->setOption('output', $input->getOption('output')); @@ -194,7 +195,7 @@ class Create extends Base { $listCommand->listMounts($user, [$mount], $listInput, $output); } - protected function getStorageService(string $userId) { + protected function getStorageService(string $userId): StoragesService { if (!empty($userId)) { $user = $this->userManager->get($userId); if (is_null($user)) { |