Code Duplication    Length = 11-11 lines in 2 locations

src/Service/SiteService.php 2 locations

@@ 36-46 (lines=11) @@
33
     *
34
     * @return Site
35
     */
36
    public function getSite(int $id): Site
37
    {
38
        $path = sprintf('sites/%d', $id);
39
40
        $response = $this->getClient()->sendRequest('GET', $path);
41
42
        /** @var Site $model */
43
        $model = $this->getModelFactory()->create(Site::class, $response);
44
45
        return $model;
46
    }
47
48
    /**
49
     * @param SitePostMessage $message
@@ 99-109 (lines=11) @@
96
     *
97
     * @return Site[]
98
     */
99
    public function getPlatformChildren(PlatformChildrenListMessage $message): array
100
    {
101
        $path = sprintf('platform/%d/children', $message->getSiteId());
102
103
        $response = $this->getClient()->sendRequest('GET', $path);
104
105
        /** @var Site[] $models */
106
        $models = $this->getModelFactory()->createMany(Site::class, $response);
107
108
        return $models;
109
    }
110
}
111