Code Duplication    Length = 19-19 lines in 4 locations

app/Http/Controllers/Projects/GraphsController.php 1 location

@@ 9-27 (lines=19) @@
6
use Gitamin\Models\Project;
7
use Illuminate\Support\Facades\View;
8
9
class GraphsController extends Controller
10
{
11
    protected $active_item = 'graphs';
12
13
    /**
14
     * Display a listing of the resource.
15
     *
16
     * @return \Illuminate\Http\Response
17
     */
18
    public function indexAction($namespace, $project_path)
19
    {
20
        $project = Project::findByPath($namespace, $project_path);
21
22
        return View::make('projects.graphs.index')
23
            ->withProject($project)
24
            ->withWikis([])
25
            ->withActiveItem($this->active_item)
26
            ->withPageTitle(sprintf('%s - %s', trans('dashboard.issues.issues'), $project->name));
27
    }
28
}
29

app/Http/Controllers/Projects/PullRequestsController.php 1 location

@@ 9-27 (lines=19) @@
6
use Gitamin\Models\Project;
7
use Illuminate\Support\Facades\View;
8
9
class PullRequestsController extends Controller
10
{
11
    protected $active_item = 'pulls';
12
13
    /**
14
     * Display a listing of the resource.
15
     *
16
     * @return \Illuminate\Http\Response
17
     */
18
    public function indexAction($namespace, $project_path)
19
    {
20
        $project = Project::findByPath($namespace, $project_path);
21
22
        return View::make('projects.pulls.index')
23
            ->withProject($project)
24
            ->withPullRequests([])
25
            ->withActiveItem($this->active_item)
26
            ->withPageTitle(sprintf('%s - %s', trans('dashboard.issues.issues'), $project->name));
27
    }
28
}
29

app/Http/Controllers/Projects/PulseController.php 1 location

@@ 9-27 (lines=19) @@
6
use Gitamin\Models\Project;
7
use Illuminate\Support\Facades\View;
8
9
class PulseController extends Controller
10
{
11
    protected $active_item = 'pulse';
12
13
    /**
14
     * Display a listing of the resource.
15
     *
16
     * @return \Illuminate\Http\Response
17
     */
18
    public function indexAction($namespace, $project_path)
19
    {
20
        $project = Project::findByPath($namespace, $project_path);
21
22
        return View::make('projects.pulse.index')
23
            ->withProject($project)
24
            ->withWikis([])
25
            ->withActiveItem($this->active_item)
26
            ->withPageTitle(sprintf('%s - %s', trans('dashboard.issues.issues'), $project->name));
27
    }
28
}
29

app/Http/Controllers/Projects/WikiController.php 1 location

@@ 9-27 (lines=19) @@
6
use Gitamin\Models\Project;
7
use Illuminate\Support\Facades\View;
8
9
class WikiController extends Controller
10
{
11
    protected $active_item = 'wiki';
12
13
    /**
14
     * Display a listing of the resource.
15
     *
16
     * @return \Illuminate\Http\Response
17
     */
18
    public function indexAction($namespace, $project_path)
19
    {
20
        $project = Project::findByPath($namespace, $project_path);
21
22
        return View::make('projects.wiki.index')
23
            ->withProject($project)
24
            ->withWikis([])
25
            ->withActiveItem($this->active_item)
26
            ->withPageTitle(sprintf('%s - %s', trans('dashboard.issues.issues'), $project->name));
27
    }
28
}
29