aboutsummaryrefslogtreecommitdiffstats
path: root/apps/files/command
diff options
context:
space:
mode:
authorVincent Petry <pvince81@owncloud.com>2014-06-26 11:58:38 +0200
committerVincent Petry <pvince81@owncloud.com>2014-06-26 11:58:38 +0200
commitfd04b3070fd88679778a806764baf0989d95f161 (patch)
tree5a87b15fff88424580101786298003824c1aa08e /apps/files/command
parent1822bba5e941862323117e2625361098ce729155 (diff)
downloadnextcloud-server-fd04b3070fd88679778a806764baf0989d95f161.tar.gz
nextcloud-server-fd04b3070fd88679778a806764baf0989d95f161.zip
Add error message when no users specified to files:scan command
Diffstat (limited to 'apps/files/command')
-rw-r--r--apps/files/command/scan.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/apps/files/command/scan.php b/apps/files/command/scan.php
index 25ab70af362..1e7b54bb01e 100644
--- a/apps/files/command/scan.php
+++ b/apps/files/command/scan.php
@@ -63,6 +63,11 @@ class Scan extends Command {
$users = $input->getArgument('user_id');
}
+ if (count($users) === 0) {
+ $output->writeln("<error>Please specify the user id to scan or \"--all\" to scan for all users</error>");
+ return;
+ }
+
foreach ($users as $user) {
if (is_object($user)) {
$user = $user->getUID();