SingleDigitInstallmentFormatter::format()   A
last analyzed

Complexity

Conditions 3
Paths 4

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 3
rs 10
c 0
b 0
f 0
cc 3
eloc 1
nc 4
nop 1
1
<?php
2
namespace Paranoia\Formatter;
3
4
class SingleDigitInstallmentFormatter implements FormatterInterface
5
{
6
    public function format($input)
7
    {
8
        return (!is_numeric($input) || intval($input) <= 1) ? null : $input;
9
    }
10
}
11