Completed
Pull Request — master (#1)
by Dorian
02:14
created

Skippable   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 1
dl 0
loc 18
c 0
b 0
f 0
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A skip() 0 10 2
1
<?php declare(strict_types=1);
2
3
namespace App\UI;
4
5
trait Skippable
6
{
7
    /**
8
     * @param \App\UI\UserInterface $ui
9
     *
10
     * @return bool
11
     */
12
    protected function skip(UserInterface $ui): bool
13
    {
14
        if ($ui->isDryRun()) {
15
            $ui->writeln('<info>[DRY-RUN]</info> Not doing anything...'.PHP_EOL);
16
17
            return true;
18
        }
19
20
        return false;
21
    }
22
}
23