Passed
Branch master (ac8b07)
by Robert
03:36
created

Transfers::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 8
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 8
ccs 0
cts 3
cp 0
rs 9.4285
c 0
b 0
f 0
cc 1
eloc 4
nc 1
nop 1
crap 2
1
<?php
2
3
namespace LivePersonInc\LiveEngageLaravel\Collections;
4
5
use Illuminate\Support\Collection;
6
use LivePersonInc\LiveEngageLaravel\Models\Transfer;
7
8
class Transfers extends Collection
9
{
10
	public function __construct(array $models = [])
11
	{
12
		
13
		$models = array_map(function($item) {
14
			return new Transfer((array) $item);
15
		}, $models);
16
		
17
		parent::__construct($models);
18
	}
19
}