Conditions | 3 |
Paths | 1 |
Total Lines | 14 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 12 |
Changes | 0 |
1 | <?php |
||
15 | private function folderResolveName() { |
||
|
|||
16 | return function($name, array $context) use ($folders, $sep) { |
||
17 | if (strpos($name, $sep) === false) { |
||
18 | return $name; |
||
19 | } |
||
20 | |||
21 | list($folder, $path) = explode($sep, $name); |
||
22 | if (!isset($folders[$folder])) { |
||
23 | return $name; |
||
24 | } |
||
25 | |||
26 | return Plates\Util\joinPath([$folders[$folder], $path]); |
||
27 | }; |
||
28 | } |
||
29 | |||
41 |