Completed
Push — master ( a19a47...15bbc5 )
by Arjay
15:59
created

WidgetServiceProvider::boot()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 2
nc 1
nop 0
dl 0
loc 4
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace Yajra\CMS\Providers;
4
5
use Illuminate\Support\ServiceProvider;
6
use Yajra\CMS\Console\WidgetMakeCommand;
7
use Yajra\CMS\Console\WidgetPublishCommand;
8
9
class WidgetServiceProvider extends ServiceProvider
10
{
11
    /**
12
     * Bootstrap the application services.
13
     *
14
     * @return void
15
     */
16
    public function boot()
17
    {
18
        $this->commands(WidgetPublishCommand::class);
19
    }
20
21
    /**
22
     * Register the application services.
23
     *
24
     * @return void
25
     */
26
    public function register()
27
    {
28
        // override arrilot widget command.
29
        $this->app->singleton('command.widget.make', function ($app) {
30
            return new WidgetMakeCommand($app['files']);
31
        });
32
    }
33
}
34