Skip to content

Commit

Permalink
Merge pull request #39 from skug/doublecheck-dependency-dirs
Browse files Browse the repository at this point in the history
* double check presence of vendor directories
  • Loading branch information
MarvinKlemp committed Oct 20, 2015
2 parents 84300e5 + 2e4d072 commit 8d87a55
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/RuleSet/Loader/ComposerLoader.php
Original file line number Diff line number Diff line change
Expand Up @@ -119,16 +119,16 @@ private function getComposerPackages(\stdClass $composer, $noDev = false)
/**
* @param $package
*
* @return RuleSet
* @return RuleSet|null
*/
private function loadPackageRuleSet(\stdClass $package)
{
$key = $this->generatePackageKey($package);
$ruleSet = null;
$key = $this->generatePackageKey($package);

if ($this->cache->has($key)) {
$ruleSet = $this->cache->getCachedRuleSet($key);
} else {
$path = $this->getPackagePath($package);
} elseif (is_dir($path = $this->getPackagePath($package))) {
$ruleSet = $this->traverser->traverse($path, true);
$this->cache->cacheRuleSet($key, $ruleSet);
}
Expand Down

0 comments on commit 8d87a55

Please sign in to comment.