Code Duplication    Length = 30-32 lines in 6 locations

src/WebHemi/Middleware/Action/Website/Directory/ArchiveAction.php 1 location

@@ 28-58 (lines=31) @@
25
/**
26
 * Class ArchiveAction.
27
 */
28
class ArchiveAction extends AbstractMiddlewareAction
29
{
30
    /**
31
     * Gets template map name or template file path.
32
     *
33
     * @return string
34
     */
35
    public function getTemplateName() : string
36
    {
37
        return 'website-post-list';
38
    }
39
40
    /**
41
     * Gets template data.
42
     *
43
     * @return array
44
     */
45
    public function getTemplateData() : array
46
    {
47
        $blogPosts = [];
48
        $title = '';
49
        $parameters = $this->getRoutingParameters();
50
51
52
        return [
53
            'title' => $title,
54
            'activeMenu' => $parameters['uri_parameter'],
55
            'blogPosts' => $blogPosts,
56
        ];
57
    }
58
}
59

src/WebHemi/Middleware/Action/Website/Directory/BinaryAction.php 1 location

@@ 21-50 (lines=30) @@
18
/**
19
 * Class BinaryAction.
20
 */
21
class BinaryAction extends AbstractMiddlewareAction
22
{
23
    /**
24
     * Gets template map name or template file path.
25
     *
26
     * @return string
27
     */
28
    public function getTemplateName() : string
29
    {
30
        return 'website-post-list';
31
    }
32
33
    /**
34
     * Gets template data.
35
     *
36
     * @return array
37
     */
38
    public function getTemplateData() : array
39
    {
40
        $blogPosts = [];
41
        $title = '';
42
        $currentMenu = '';
43
44
        return [
45
            'title' => $title,
46
            'activeMenu' => $currentMenu,
47
            'blogPosts' => $blogPosts,
48
        ];
49
    }
50
}
51

src/WebHemi/Middleware/Action/Website/Directory/CategoryAction.php 1 location

@@ 28-59 (lines=32) @@
25
/**
26
 * Class CategoryAction.
27
 */
28
class CategoryAction extends AbstractMiddlewareAction
29
{
30
    /**
31
     * Gets template map name or template file path.
32
     *
33
     * @return string
34
     */
35
    public function getTemplateName() : string
36
    {
37
        return 'website-post-list';
38
    }
39
40
    /**
41
     * Gets template data.
42
     *
43
     * @return array
44
     */
45
    public function getTemplateData() : array
46
    {
47
        $blogPosts = [];
48
        $title = '';
49
        $parameters = $this->getRoutingParameters();
50
51
52
53
        return [
54
            'title' => $title,
55
            'activeMenu' => $parameters['uri_parameter'],
56
            'blogPosts' => $blogPosts,
57
        ];
58
    }
59
}
60

src/WebHemi/Middleware/Action/Website/Directory/GalleryAction.php 1 location

@@ 21-50 (lines=30) @@
18
/**
19
 * Class GalleryAction.
20
 */
21
class GalleryAction extends AbstractMiddlewareAction
22
{
23
    /**
24
     * Gets template map name or template file path.
25
     *
26
     * @return string
27
     */
28
    public function getTemplateName() : string
29
    {
30
        return 'website-post-list';
31
    }
32
33
    /**
34
     * Gets template data.
35
     *
36
     * @return array
37
     */
38
    public function getTemplateData() : array
39
    {
40
        $blogPosts = [];
41
        $title = '';
42
        $currentMenu = '';
43
44
        return [
45
            'title' => $title,
46
            'activeMenu' => $currentMenu,
47
            'blogPosts' => $blogPosts,
48
        ];
49
    }
50
}
51

src/WebHemi/Middleware/Action/Website/Directory/PostAction.php 1 location

@@ 21-50 (lines=30) @@
18
/**
19
 * Class PostAction.
20
 */
21
class PostAction extends AbstractMiddlewareAction
22
{
23
    /**
24
     * Gets template map name or template file path.
25
     *
26
     * @return string
27
     */
28
    public function getTemplateName() : string
29
    {
30
        return 'website-post-list';
31
    }
32
33
    /**
34
     * Gets template data.
35
     *
36
     * @return array
37
     */
38
    public function getTemplateData() : array
39
    {
40
        $blogPosts = [];
41
        $title = '';
42
        $currentMenu = '';
43
44
        return [
45
            'title' => $title,
46
            'activeMenu' => $currentMenu,
47
            'blogPosts' => $blogPosts,
48
        ];
49
    }
50
}
51

src/WebHemi/Middleware/Action/Website/Directory/TagAction.php 1 location

@@ 28-58 (lines=31) @@
25
/**
26
 * Class TagAction.
27
 */
28
class TagAction extends AbstractMiddlewareAction
29
{
30
    /**
31
     * Gets template map name or template file path.
32
     *
33
     * @return string
34
     */
35
    public function getTemplateName() : string
36
    {
37
        return 'website-post-list';
38
    }
39
40
    /**
41
     * Gets template data.
42
     *
43
     * @return array
44
     */
45
    public function getTemplateData() : array
46
    {
47
        $blogPosts = [];
48
        $title = '';
49
        $parameters = $this->getRoutingParameters();
50
51
52
        return [
53
            'title' => $title,
54
            'activeMenu' => $parameters['uri_parameter'],
55
            'blogPosts' => $blogPosts,
56
        ];
57
    }
58
}
59