ServiceProvider   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 8
dl 0
loc 21
ccs 10
cts 10
cp 1
rs 10
c 1
b 0
f 0
wmc 3

2 Methods

Rating   Name   Duplication   Size   Complexity  
A boot() 0 9 2
A register() 0 3 1
1
<?php
2
3
namespace LaravelDownloadUtil;
4
5
use LaravelDownloadUtil\Console\Commands\PruneOutdatedFiles;
6
7
class ServiceProvider extends \Illuminate\Support\ServiceProvider
8
{
9 8
    public function boot()
10
    {
11 8
        if ($this->app->runningInConsole()) {
12 8
            $this->publishes([
13 8
                __DIR__.'/../config/download-util.php' => config_path('download-util.php'),
14 8
            ], 'config');
15
16 8
            $this->commands([
17 8
                PruneOutdatedFiles::class,
18 8
            ]);
19
        }
20
    }
21
22
    /**
23
     * @inheritDoc
24
     */
25 8
    public function register()
26
    {
27 8
        $this->mergeConfigFrom(__DIR__.'/../config/download-util.php', 'download-util');
28
    }
29
}
30