Kernel::getArtisan()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 8
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 6

Importance

Changes 0
Metric Value
eloc 4
dl 0
loc 8
c 0
b 0
f 0
ccs 0
cts 5
cp 0
rs 10
cc 2
nc 2
nop 0
crap 6
1
<?php
2
3
declare(strict_types=1);
4
5
namespace FondBot\Framework\Console;
6
7
use Illuminate\Foundation\Console\Kernel as BaseKernel;
8
9
class Kernel extends BaseKernel
10
{
11
    /** {@inheritdoc} */
12
    protected function getArtisan()
13
    {
14
        if ($this->artisan === null) {
15
            return $this->artisan = (new Application($this->app, $this->events, $this->app->version()))
16
                ->resolveCommands($this->commands);
17
        }
18
19
        return $this->artisan;
20
    }
21
}
22