diff options
Diffstat (limited to 'apps/files_trashbin/lib/Command/CleanUp.php')
-rw-r--r-- | apps/files_trashbin/lib/Command/CleanUp.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/apps/files_trashbin/lib/Command/CleanUp.php b/apps/files_trashbin/lib/Command/CleanUp.php index 7192ed26094..1b61c1ae74d 100644 --- a/apps/files_trashbin/lib/Command/CleanUp.php +++ b/apps/files_trashbin/lib/Command/CleanUp.php @@ -77,7 +77,7 @@ class CleanUp extends Command { ); } - protected function execute(InputInterface $input, OutputInterface $output) { + protected function execute(InputInterface $input, OutputInterface $output): int { $users = $input->getArgument('user_id'); if ((!empty($users)) and ($input->getOption('all-users'))) { throw new InvalidOptionException('Either specify a user_id or --all-users'); @@ -88,6 +88,7 @@ class CleanUp extends Command { $this->removeDeletedFiles($user); } else { $output->writeln("<error>Unknown user $user</error>"); + return 1; } } } elseif ($input->getOption('all-users')) { @@ -112,6 +113,7 @@ class CleanUp extends Command { } else { throw new InvalidOptionException('Either specify a user_id or --all-users'); } + return 0; } /** |