Completed
Push — master ( 6ff8ac...850b68 )
by Tom
86:44 queued 66:31
created

FileLocator   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 2
c 1
b 0
f 0
lcom 0
cbo 0
dl 0
loc 18
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A locate() 0 10 2
1
<?php
2
3
namespace TomPHP\ConfigServiceProvider\FileReader;
4
5
final class FileLocator
6
{
7
    /**
8
     * @param array $patterns
9
     *
10
     * @return string[]
11
     */
12
    public function locate(array $patterns)
13
    {
14
        $files = [];
15
16
        foreach ($patterns as $pattern) {
17
            $files = array_merge($files, glob($pattern, GLOB_BRACE));
18
        }
19
20
        return $files;
21
    }
22
}
23