Completed
Pull Request — master (#6)
by
unknown
01:22
created

ViewModelsServiceProvider::boot()   A

Complexity

Conditions 2
Paths 2

Size

Total Lines 8

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 8
rs 10
c 0
b 0
f 0
cc 2
nc 2
nop 0
1
<?php
2
3
namespace Spatie\ViewModels\Providers;
4
5
use Illuminate\Support\ServiceProvider;
6
use Spatie\ViewModels\Commands\ViewModelMakeCommand;
7
8
class ViewModelsServiceProvider extends ServiceProvider
9
{
10
    /**
11
     * Register bindings in the container.
12
     *
13
     * @return void
14
     */
15
    public function register()
16
    {
17
    }
18
19
    public function boot()
20
    {
21
        if ($this->app->runningInConsole()) {
22
            $this->commands([
23
                ViewModelMakeCommand::class,
24
            ]);
25
        }
26
    }
27
}
28