diff --git a/bin/phpstan b/bin/phpstan index aff3331ea2..a8c0fd8dd0 100755 --- a/bin/phpstan +++ b/bin/phpstan @@ -93,11 +93,7 @@ use Symfony\Component\Console\Helper\ProgressBar; } $autoloadProjectAutoloaderFile = function (string $file) use (&$composerAutoloaderProjectPaths): void { - $path = realpath(dirname(__DIR__) . $file); - if ($path === false) { - return; - } - + $path = dirname(__DIR__) . $file; if (!extension_loaded('phar')) { if (@is_file($path)) { $composerAutoloaderProjectPaths[] = dirname($path, 2); @@ -113,8 +109,8 @@ use Symfony\Component\Console\Helper\ProgressBar; require_once $path; } } else { - $path = realpath(dirname($pharPath) . $file); - if ($path !== false && @is_file($path)) { + $path = dirname($pharPath) . $file; + if (@is_file($path)) { $composerAutoloaderProjectPaths[] = dirname($path, 2); require_once $path;