8000 Fix dir detection without vendor · symfony/requirements-checker@d1505e7 · GitHub
[go: up one dir, main page]

Skip to content

Commit d1505e7

Browse files
committed
Fix dir detection without vendor
1 parent 0aceaa4 commit d1505e7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bin/requirements-checker.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
$requirements = $symfonyRequirements->getRequirements();
4141

4242
// specific directory to check?
43-
$dir = isset($args[1]) ? $args[1] : dirname(dirname(realpath($autoloader)));
43+
$dir = isset($args[1]) ? $args[1] : (file_exists(getcwd().'/composer.json') ? getcwd().'/composer.json' : null);
4444
if (null !== $dir) {
4545
$projectRequirements = new ProjectRequirements($dir);
4646
$requirements = array_merge($requirements, $projectRequirements->getRequirements());

0 commit comments

Comments
 (0)
0