Completed
Push — master ( c18c1e...ad6735 )
by ARCANEDEV
12s
created

Policy   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A before() 0 4 2
1
<?php namespace Arcanesoft\Auth\Policies;
2
3
use Arcanesoft\Contracts\Auth\Models\User;
4
5
/**
6
 * Class     Policy
7
 *
8
 * @package  Arcanesoft\Auth\Policies
9
 * @author   ARCANEDEV <[email protected]>
10
 */
11
abstract class Policy
12
{
13
    /* ------------------------------------------------------------------------------------------------
14
     |  Main Functions
15
     | ------------------------------------------------------------------------------------------------
16
     */
17
    /**
18
     * @param  \Arcanesoft\Contracts\Auth\Models\User  $user
19
     * @param  mixed                                   $ability
20
     *
21
     * @return bool
22
     */
23
    public function before(User $user, $ability)
0 ignored issues
show
Unused Code introduced by
The parameter $ability is not used and could be removed.

This check looks from parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
24
    {
25
        if ($user->isAdmin()) return true;
26
    }
27
}
28