replace symfony console return values

This commit is contained in:
crazywhalecc
2023-08-06 10:43:20 +08:00
committed by Jerry Ma
parent 7a1433a994
commit a1e4125ded
15 changed files with 42 additions and 44 deletions

View File

@@ -26,10 +26,10 @@ class ExtractCommand extends BaseCommand
$sources = array_map('trim', array_filter(explode(',', $this->getArgument('sources'))));
if (empty($sources)) {
$this->output->writeln('<error>sources cannot be empty, at least contain one !</error>');
return 1;
return static::FAILURE;
}
SourceExtractor::initSource(sources: $sources);
logger()->info('Extract done !');
return 0;
return static::SUCCESS;
}
}