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 — 1.0 ( 145725...d072b4 )
by Henrique
03:07
created

GermanBank::validate()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 4
c 0
b 0
f 0
ccs 0
cts 4
cp 0
rs 10
cc 1
eloc 2
nc 1
nop 1
crap 2
1
<?php
2
3
/*
4
 * This file is part of Respect/Validation.
5
 *
6
 * (c) Alexandre Gomes Gaigalas <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the "LICENSE.md"
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Respect\Validation\Rules\Locale;
13
14
use malkusch\bav\BAV;
15
use Respect\Validation\Rules\AbstractRule;
16
17
/**
18
 * Validates a german bank.
19
 *
20
 * This validator depends on the composer package "malkusch/bav".
21
 *
22
 * @author Markus Malkusch <[email protected]>
23
 *
24
 * @see    BAV::isValidBank()
25
 */
26
class GermanBank extends AbstractRule
27
{
28
    /**
29
     * @var BAV
30
     */
31
    public $bav;
32
33
    /**
34
     * @param BAV $bav
35
     */
36
    public function __construct(BAV $bav = null)
37
    {
38
        if (null === $bav) {
39
            $bav = new BAV();
40
        }
41
        $this->bav = $bav;
42
    }
43
44
    /**
45
     * @return bool
46
     */
47
    public function validate($input)
48
    {
49
        return $this->bav->isValidBank($input);
50
    }
51
}
52