Code Duplication    Length = 14-16 lines in 2 locations

src/AppBundle/Controller/MetaController.php 1 location

@@ 28-41 (lines=14) @@
25
     * @param Request $request
26
     * @return Response
27
     */
28
    public function indexAction(Request $request)
29
    {
30
        $params = $this->parseQueryParams($request);
31
32
        if (isset($params['start']) && isset($params['end'])) {
33
            return $this->redirectToRoute('MetaResult', $params);
34
        }
35
36
        return $this->render('meta/index.html.twig', [
37
            'xtPage' => 'meta',
38
            'xtPageTitle' => 'tool-meta',
39
            'xtSubtitle' => 'tool-meta-desc',
40
        ]);
41
    }
42
43
    /**
44
     * Display the results.

src/AppBundle/Controller/AdminStatsController.php 1 location

@@ 89-104 (lines=16) @@
86
     *
87
     * @return Route|\Symfony\Component\HttpFoundation\Response
88
     */
89
    public function indexAction(Request $request)
90
    {
91
        $params = $this->parseQueryParams($request);
92
93
        // Redirect if we have a project. $results may also include start and/or end date.
94
        if (isset($params['project'])) {
95
            return $this->redirectToRoute('AdminStatsResult', $params);
96
        }
97
98
        // Otherwise render form.
99
        return $this->render('adminStats/index.html.twig', [
100
            'xtPage' => 'adminstats',
101
            'xtPageTitle' => 'tool-adminstats',
102
            'xtSubtitle' => 'tool-adminstats-desc',
103
        ]);
104
    }
105
106
    /**
107
     * Method for rendering the AdminStats Results