We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
Conditions | 8 |
Paths | 25 |
Total Lines | 44 |
Code Lines | 23 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
18 | } else { |
||
19 | $this->data[$attribute] = []; |
||
20 | } |
||
21 | $value = []; |
||
22 | } |
||
23 | |||
24 | $previousValues = $entry?->{$attribute} ?? []; |
||
25 | if (is_string($previousValues)) { |
||
26 | $previousValues = json_decode($previousValues, true) ?? []; |
||
27 | } |
||
28 | |||
29 | $value = array_merge($previousValues, $value); |
||
30 | |||
31 | if ($entry) { |
||
32 | $filesDeleted = CrudPanelFacade::getRequest()->input('clear_'.$attribute) ?? []; |
||
33 | |||
34 | $data = $this->data; |
||
35 | $data[$attribute] = array_diff($value, $filesDeleted); |
||
36 | |||
37 | return $this->validateFieldAndFile($attribute, $value, $data); |
||
38 | } |
||
39 | |||
40 | return $this->validateFieldAndFile($attribute, $value); |
||
41 | } |
||
42 | } |
||
43 |