protected function execute(InputInterface $input, OutputInterface $output) { if ($input->getOption('all')) { /** @var $mounts StorageConfig[] */ $mounts = $this->globalService->getStorageForAllUsers(); $userId = self::ALL; } else { $userId = $input->getArgument('user_id'); $storageService = $this->getStorageService($userId); /** @var $mounts StorageConfig[] */ $mounts = $storageService->getAllStorages(); } $this->listMounts($userId, $mounts, $input, $output); }