Completed
Push — master ( 30ea98...ad161f )
by Jake
02:20
created

PagesController::generateSEO()   B

Complexity

Conditions 4
Paths 8

Size

Total Lines 35
Code Lines 31

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 4
eloc 31
c 1
b 0
f 0
nc 8
nop 2
dl 0
loc 35
rs 8.5806
1
<?php
2
3
namespace MeestorHok\Blue\Http\Controllers;
4
 
5
use Illuminate\Routing\Controller;
6
use Request;
7
8
//use MeestorHok\Blue\Models\Site;
0 ignored issues
show
Unused Code Comprehensibility introduced by
39% of this comment could be valid code. Did you maybe forget this after debugging?

Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.

The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.

This check looks for comments that seem to be mostly valid code and reports them.

Loading history...
9
//use MeestorHok\Blue\Models\Page as Page;
10
use MeestorHok\Blue\SEOGenerator as SEO;
11
12
class PagesController extends Controller
13
{
14
    public function page ($page = null) {
15
        if (is_null($page)) {
16
            return SEO::make([], 'Blue::home');
17
        }
18
        return '<h1>'.$page.'</h1>';
19
    }
20
}