Total Complexity | 2 |
Total Lines | 12 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
8 | trait TransformsResources |
||
9 | { |
||
10 | protected function transformCollection(array $items, string $class): Collection |
||
11 | { |
||
12 | return collect($items)->map(function ($attributes) use ($class) { |
||
13 | return $this->transformItem($attributes, $class); |
||
14 | }); |
||
15 | } |
||
16 | |||
17 | protected function transformItem(array $attributes, string $class): ApiResource |
||
20 | } |
||
21 | } |
||
22 |