UpdateCommand::getInitializerInstance()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
cc 1
nc 1
nop 1
dl 0
loc 4
ccs 2
cts 2
cp 1
crap 1
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace MadWeb\Initializer\Console\Commands;
4
5
use Illuminate\Contracts\Container\Container;
6
7
class UpdateCommand extends AbstractInitializeCommand
8
{
9
    /**
10
     * The name and signature of the console command.
11
     *
12
     * @var string
13
     */
14
    protected $signature = 'app:update
15
                            {--root : Run commands which requires root privileges}';
16
17
    /**
18
     * The console command description.
19
     *
20
     * @var string
21
     */
22
    protected $description = 'Update the application according to current environment';
23
24
    /**
25
     * Returns instance of Update class which defines initializing runner chain.
26
     *
27
     * {@inheritdoc}
28
     */
29 105
    protected function getInitializerInstance(Container $container)
30
    {
31 105
        return $container->make('app.updater');
32
    }
33
34 105
    protected function title(): string
35
    {
36 105
        return 'Application update';
37
    }
38
}
39