CascadeDeleteServiceProvider   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 7
dl 0
loc 16
rs 10
c 1
b 0
f 0
wmc 2

1 Method

Rating   Name   Duplication   Size   Complexity  
A boot() 0 9 2
1
<?php
2
3
namespace Cesargb\Database\Support;
4
5
use Cesargb\Database\Support\Commands\MorphCleanCommand;
6
use Illuminate\Support\ServiceProvider;
7
8
class CascadeDeleteServiceProvider extends ServiceProvider
9
{
10
    /**
11
     * Bootstrap the application services.
12
     *
13
     * @return void
14
     */
15
    public function boot()
16
    {
17
        $this->publishes([
18
            __DIR__.'/../config/morph.php' => config_path('morph.php'),
19
        ], 'config');
20
21
        if ($this->app->runningInConsole()) {
22
            $this->commands([
23
                MorphCleanCommand::class,
24
            ]);
25
        }
26
    }
27
}
28