Conditions | 4 |
Paths | 5 |
Total Lines | 15 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 4 |
CRAP Score | 6 |
Changes | 0 |
1 | <?php |
||
33 | 5 | protected function parseFileAttributes(): array |
|
34 | { |
||
35 | 5 | $files = []; |
|
36 | 5 | foreach ($this->fileAttributes as $attribute => $value) { |
|
37 | if (is_int($attribute)) { |
||
38 | $attribute = $value; |
||
39 | } |
||
40 | if (null !== ($uploadedFile = UploadedFile::getInstanceByName( |
||
41 | $value |
||
42 | ))) { |
||
43 | $files[$attribute] = $uploadedFile; |
||
44 | } |
||
45 | } |
||
46 | |||
47 | 5 | return $files; |
|
48 | } |
||
50 |