File tree Expand file tree Collapse file tree 1 file changed +2
-7
lines changed
Expand file tree Collapse file tree 1 file changed +2
-7
lines changed Original file line number Diff line number Diff line change 1818use function array_map ;
1919use function array_values ;
2020use function iterator_to_array ;
21- use function pathinfo ;
22-
23- use const PATHINFO_EXTENSION ;
2421
2522/**
2623 * This source locator loads all php files from \FileSystemIterator
@@ -56,13 +53,11 @@ private function getAggregatedSourceLocator(): AggregateSourceLocator
5653 return $ this ->aggregateSourceLocator
5754 ?? $ this ->aggregateSourceLocator = new AggregateSourceLocator (array_values (array_filter (array_map (
5855 function (SplFileInfo $ item ): SingleFileSourceLocator |null {
59- $ realPath = $ item ->getRealPath ();
60-
61- if (! ($ item ->isFile () && pathinfo ($ realPath , PATHINFO_EXTENSION ) === 'php ' )) {
56+ if (! ($ item ->isFile () && $ item ->getExtension () === 'php ' )) {
6257 return null ;
6358 }
6459
65- return new SingleFileSourceLocator ($ realPath , $ this ->astLocator );
60+ return new SingleFileSourceLocator ($ item -> getRealPath () , $ this ->astLocator );
6661 },
6762 iterator_to_array ($ this ->fileSystemIterator ),
6863 ))));
You can’t perform that action at this time.
0 commit comments