AppServiceProvider   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 31
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Test Coverage

Coverage 77.78%

Importance

Changes 0
Metric Value
dl 0
loc 31
ccs 7
cts 9
cp 0.7778
rs 10
c 0
b 0
f 0
wmc 4
lcom 1
cbo 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A boot() 0 6 1
A register() 0 11 3
1
<?php
2
3
namespace App\Providers;
4
5
use Illuminate\Support\ServiceProvider;
6
use Laravel\Dusk\DuskServiceProvider;
7
8
class AppServiceProvider extends ServiceProvider
9
{
10
    /**
11
     * Bootstrap any application services.
12
     *
13
     * @return void
14
     */
15 87
    public function boot()
16
    {
17
//app('Dingo\Api\Auth\Auth')->extend('basic', function ($app) {
0 ignored issues
show
Unused Code Comprehensibility introduced by
69% 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...
18
//   return new Dingo\Api\Auth\Provider\Basic($app['auth'], 'username');
19
//});
20 87
    }
21
22
    /**
23
     * Register any application services.
24
     *
25
     * @return void
26
     */
27 87
    public function register()
28
    {
29 87
        if ($this->app->environment() == 'development') {
30
            $this->app->register(\Laravel\Tinker\TinkerServiceProvider::class);
31
            $this->app->register('Barryvdh\LaravelIdeHelper\IdeHelperServiceProvider');
32
        }
33
34 87
        if ($this->app->environment('development', 'testing')) {
35 87
            $this->app->register(DuskServiceProvider::class);
36
        }
37 87
    }
38
}
39