Code Duplication    Length = 13-13 lines in 2 locations

htdocs/src/Oc/Page/BlockRepository.php 1 location

@@ 182-194 (lines=13) @@
179
     *
180
     * @return BlockEntity
181
     */
182
    public function getEntityFromDatabaseArray(array $data)
183
    {
184
        $entity = new BlockEntity();
185
        $entity->id = (int) $data['id'];
186
        $entity->pageId = (int) $data['page_id'];
187
        $entity->title = (string) $data['title'];
188
        $entity->html = (string) $data['html'];
189
        $entity->position = (int) $data['position'];
190
        $entity->updatedAt = new DateTime($data['updated_at']);
191
        $entity->active = (bool) $data['active'];
192
193
        return $entity;
194
    }
195
}
196

htdocs/src/Oc/Page/PageRepository.php 1 location

@@ 180-192 (lines=13) @@
177
     *
178
     * @return PageEntity
179
     */
180
    public function getEntityFromDatabaseArray(array $data)
181
    {
182
        $entity = new PageEntity();
183
        $entity->id = (int) $data['id'];
184
        $entity->slug = (string) $data['slug'];
185
        $entity->metaKeywords = (string) $data['meta_keywords'];
186
        $entity->metaDescription = (string) $data['meta_description'];
187
        $entity->metaSocial = (string) $data['meta_social'];
188
        $entity->updatedAt = new DateTime($data['updated_at']);
189
        $entity->active = (bool) $data['active'];
190
191
        return $entity;
192
    }
193
}
194