Conditions | 4 |
Paths | 8 |
Total Lines | 23 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 20 |
Changes | 0 |
1 | <?php |
||
15 | public function find($path, array $includes, array $excludes = []) |
||
16 | { |
||
17 | $finder = new BaseFinder(); |
||
18 | $finder->ignoreDotFiles(true) |
||
19 | ->files() |
||
20 | ->name('*.php') |
||
21 | ->in($path); |
||
22 | |||
23 | foreach ($includes as $include) { |
||
24 | $finder->path($include); |
||
25 | } |
||
26 | |||
27 | foreach ($excludes as $exclude) { |
||
28 | $finder->notPath($exclude); |
||
29 | } |
||
30 | |||
31 | $files = []; |
||
32 | foreach ($finder as $file) { |
||
33 | $files[] = $file->getRealpath(); |
||
34 | } |
||
35 | |||
36 | return $files; |
||
37 | } |
||
38 | |||
62 |