Code Duplication    Length = 18-18 lines in 2 locations

src/Comment/CommentController.php 2 locations

@@ 91-108 (lines=18) @@
88
     *
89
     * @return void
90
     */
91
    public function getPostDeleteItem()
92
    {
93
        $title      = "Delete an item";
94
        $view       = $this->di->get("view");
95
        $pageRender = $this->di->get("pageRender");
96
        $userId    = $this->di->get("session")->get("userId");
97
        $form       = new DeleteForm($this->di, $userId);
98
99
        $form->check();
100
101
        $data = [
102
            "form" => $form->getHTML(),
103
        ];
104
105
        $view->add("comment/delete", $data);
106
107
        $pageRender->renderPage(["title" => $title]);
108
    }
109
110
111
@@ 117-134 (lines=18) @@
114
     *
115
     * @return void
116
     */
117
    public function getPostUpdateItem($id)
118
    {
119
        $title      = "Update an item";
120
        $view       = $this->di->get("view");
121
        $pageRender = $this->di->get("pageRender");
122
        $userId    = $this->di->get("session")->get("userId");
123
        $form       = new UpdateForm($this->di, $id, $userId);
124
125
        $form->check();
126
127
        $data = [
128
            "form" => $form->getHTML(),
129
        ];
130
131
        $view->add("comment/update", $data);
132
133
        $pageRender->renderPage(["title" => $title]);
134
    }
135
}
136