Scrutinizer GitHub App not installed

We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.

Install GitHub App

Completed
Push — 0.9 ( 7d978d...1ce8ac )
by Henrique
07:01 queued 01:39
created

Between   A

Complexity

Total Complexity 6

Size/Duplication

Total Lines 22
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 4

Test Coverage

Coverage 100%
Metric Value
wmc 6
lcom 0
cbo 4
dl 0
loc 22
ccs 12
cts 12
cp 1
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
B __construct() 0 16 6
1
<?php
2
namespace Respect\Validation\Rules;
3
4
use Respect\Validation\Exceptions\ComponentException;
5
6
class Between extends AllOf
7
{
8
    public $minValue;
9
    public $maxValue;
10
11 23
    public function __construct($min = null, $max = null, $inclusive = false)
12
    {
13 23
        $this->minValue = $min;
14 23
        $this->maxValue = $max;
15 23
        if (!is_null($min) && !is_null($max) && $min > $max) {
16 1
            throw new ComponentException(sprintf('%s cannot be less than  %s for validation', $min, $max));
17
        }
18
19 22
        if (!is_null($min)) {
20 22
            $this->addRule(new Min($min, $inclusive));
21 22
        }
22
23 22
        if (!is_null($max)) {
24 22
            $this->addRule(new Max($max, $inclusive));
25 22
        }
26 22
    }
27
}
28