SelectionFormatterTrait   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 6
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
eloc 3
dl 0
loc 6
ccs 0
cts 3
cp 0
rs 10
c 0
b 0
f 0
wmc 2

1 Method

Rating   Name   Duplication   Size   Complexity  
A removeClearControl() 0 4 2
1
<?php
2
3
namespace WebTheory\Saveyour\Formatting\Abstracts;
4
5
trait SelectionFormatterTrait
6
{
7
    protected function removeClearControl(&$value)
8
    {
9
        if (in_array('', $value)) {
10
            $value = array_filter($value, fn ($entry) => '' !== $entry);
11
        }
12
    }
13
}
14