| Conditions | 1 |
| Paths | 1 |
| Total Lines | 8 |
| Code Lines | 4 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 25 | protected function getMediaAttributes(ContentBlock $contentBlock): array |
||
| 26 | { |
||
| 27 | return array_reduce($contentBlock->mediaLibraryCollectionNames(), function ($mediaAttributes, $collectionName) use ($contentBlock) { |
||
| 28 | $mediaAttributes[$collectionName] = fractal($contentBlock->getMedia($collectionName), new MediaTransformer())->toArray(); |
||
| 29 | |||
| 30 | return $mediaAttributes; |
||
| 31 | }, []); |
||
| 32 | } |
||
| 33 | |||
| 45 |