diff options
author | Côme Chilliet <come.chilliet@nextcloud.com> | 2023-05-02 10:01:38 +0200 |
---|---|---|
committer | Côme Chilliet <come.chilliet@nextcloud.com> | 2023-05-02 10:01:38 +0200 |
commit | 2ffa9fc79741e71c277be2913ff2e396de09a51c (patch) | |
tree | 2e58bd10453e032187178de7450c7843bcca4392 /apps/files/lib | |
parent | 1f839796998d2f0656d578c1f0ac19d773100789 (diff) | |
download | nextcloud-server-2ffa9fc79741e71c277be2913ff2e396de09a51c.tar.gz nextcloud-server-2ffa9fc79741e71c277be2913ff2e396de09a51c.zip |
Only show error stack trace on very verbose level
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Diffstat (limited to 'apps/files/lib')
-rw-r--r-- | apps/files/lib/Command/Scan.php | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/apps/files/lib/Command/Scan.php b/apps/files/lib/Command/Scan.php index fbfc9cbca50..1d59db1faa6 100644 --- a/apps/files/lib/Command/Scan.php +++ b/apps/files/lib/Command/Scan.php @@ -192,11 +192,6 @@ class Scan extends Base { $users = $input->getArgument('user_id'); } - # restrict the verbosity level to VERBOSITY_VERBOSE - if ($output->getVerbosity() > OutputInterface::VERBOSITY_VERBOSE) { - $output->setVerbosity(OutputInterface::VERBOSITY_VERBOSE); - } - # check quantity of users to be process and show it on the command line $users_total = count($users); if ($users_total === 0) { @@ -263,7 +258,8 @@ class Scan extends Base { return false; } $e = new \ErrorException($message, 0, $severity, $file, $line); - $output->writeln("\t<error>$e</error>"); + $output->writeln('<error>Error during scan: ' . $e->getMessage() . '</error>'); + $output->writeln('<error>' . $e->getTraceAsString() . '</error>', OutputInterface::VERBOSITY_VERY_VERBOSE); return true; } |