Passed
Push — master ( 8989ad...df9f47 )
by Yaroslav
02:00 queued 29s
created

StrHelper   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 10
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 0
dl 0
loc 10
ccs 4
cts 4
cp 1
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A concatIfNotEmpty() 0 7 1
1
<?php
2
3
namespace Angecode\LaravelFullName;
4
5
class StrHelper
6
{
7 2
    public static function concatIfNotEmpty(array $items, string $glue = ' ')
8
    {
9 2
        return implode(
10 2
            $glue,
11 2
            array_filter($items)
12
        );
13
    }
14
}
15