Skip to content

Commit

Permalink
Consolidate conditionals
Browse files Browse the repository at this point in the history
  • Loading branch information
muglug committed Apr 1, 2020
1 parent fc06250 commit 1a67806
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions src/Psalm/Internal/Analyzer/ProjectAnalyzer.php
Expand Up @@ -492,23 +492,17 @@ public function check($base_dir, $is_diff = false)

$this->progress->startScanningFiles();

if ($diff_files === null
|| $deleted_files === null
|| count($diff_files) > 200
) {
$this->codebase->scanner->addFilesToDeepScan($this->project_files);
}

$diff_no_files = false;

if ($diff_files === null
|| $deleted_files === null
|| count($diff_files) > 200
) {
$this->codebase->analyzer->addFilesToAnalyze($this->project_files);

$this->visitAutoloadFiles();

$this->codebase->scanner->addFilesToDeepScan($this->project_files);
$this->codebase->analyzer->addFilesToAnalyze($this->project_files);

$this->config->initializePlugins($this);

$this->codebase->scanFiles($this->threads);
Expand Down

0 comments on commit 1a67806

Please sign in to comment.