Conditions | 3 |
Paths | 2 |
Total Lines | 17 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
43 | } |
||
44 | |||
45 | if ($outlet !== null) { |
||
46 | $callable = $outlet; |
||
47 | } else { |
||
48 | $callable = function ($payload) { |
||
49 | return $payload; |
||
50 | }; |
||
51 | }; |
||
52 | |||
53 | while ($pipe = array_pop($pipes)) { |
||
54 | $callable = function (...$payload) use ($pipe, $callable) { |
||
55 | return $pipe($callable, ...$payload); |
||
56 | }; |
||
57 | } |
||
58 | |||
59 | return $callable; |
||
60 | } |
||
70 |