Completed
Push — master ( 8ed555...39dbfd )
by Renato
03:43 queued 01:01
created

ProductbacklogMiddleware   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 2
lcom 0
cbo 0
dl 0
loc 19
c 1
b 0
f 0
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A handle() 0 9 2
1
<?php
2
3
namespace GitScrum\Http\Middleware;
4
5
use Closure;
6
use GitScrum\Models\ProductBacklog;
7
use Auth;
8
9
class ProductbacklogMiddleware
10
{
11
    /**
12
     * Handle an incoming request.
13
     *
14
     * @param  \Illuminate\Http\Request  $request
15
     * @param  \Closure  $next
16
     * @return mixed
17
     */
18
    public function handle($request, Closure $next)
19
    {
20
        if ( !ProductBacklog::count() )
21
        {
22
            //return redirect()->route('wizard.step1');
23
        }
24
25
        return $next($request);
26
    }
27
}
28