Test Failed
Push — develop ( 1bbdf7...df4a96 )
by Paul
13:49
created

SanitizePostId   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 10
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 2
eloc 3
dl 0
loc 10
rs 10
c 1
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A value() 0 3 1
A run() 0 3 1
1
<?php
2
3
namespace GeminiLabs\SiteReviews\Modules\Sanitizers;
4
5
use GeminiLabs\SiteReviews\Helper;
6
7
class SanitizePostId extends IntSanitizer
8
{
9
    public function run(): int
10
    {
11
        return $this->value();
12
    }
13
14
    protected function value(): int
15
    {
16
        return Helper::getPostId($this->value);
17
    }
18
}
19