Skip to content

Commit

Permalink
[console] Validate file exists when phar is running. (#313)
Browse files Browse the repository at this point in the history
  • Loading branch information
jmolivas committed Feb 12, 2018
1 parent 483b8c6 commit cce0dbe
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/Utils/ChainDiscovery.php
Expand Up @@ -131,7 +131,12 @@ public function getFiles()
->name('*.yml')
->in($directory);
foreach ($finder as $file) {

$filePath = $file->getRealPath();
if (empty($filePath)) {
$filePath = $directory . $file->getBasename();
}

if (!is_file($filePath)) {
continue;
}
Expand Down

0 comments on commit cce0dbe

Please sign in to comment.