RoleRepositoryServiceProvider   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 3

Importance

Changes 0
Metric Value
wmc 1
lcom 1
cbo 3
dl 0
loc 16
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A register() 0 8 1
1
<?php namespace Usman\Guardian\Repositories\Providers;
2
3
4
use Illuminate\Support\ServiceProvider;
5
use Usman\Guardian\Repositories\RoleRepository;
6
7
class RoleRepositoryServiceProvider extends ServiceProvider {
8
9
    /**
10
     * Register the service provider.
11
     *
12
     * @return void
13
     */
14
    public function register()
15
    {
16
        $this->app->bind('Usman\Guardian\Repositories\Interfaces\RoleRepositoryInterface',function()
17
        {
18
            $role = config('guardian.roleModel');
19
            return new RoleRepository(new $role);
20
        });
21
    }
22
}