Conditions | 2 |
Paths | 2 |
Total Lines | 8 |
Code Lines | 5 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
37 | public function findTopPosts(string $tagName) |
||
38 | { |
||
39 | $url = Endpoint::exploreTags($tagName); |
||
40 | $data = $this->fetchContentAsArray($url); |
||
41 | |||
42 | $items = $this->exploreTagsMapper->normalizeData(Post::class, $data); |
||
43 | foreach ($items as $item) { |
||
44 | yield $this->exploreTagsMapper->populate(Post::class, $item); |
||
45 | } |
||
47 | } |