Conditions | 1 |
Paths | 1 |
Total Lines | 10 |
Code Lines | 5 |
Lines | 0 |
Ratio | 0 % |
Tests | 6 |
CRAP Score | 1 |
Changes | 0 |
1 | <?php |
||
16 | 3 | public function newCall(callable $canceller = null) |
|
17 | { |
||
18 | 3 | $uniqid = $this->getNewUniqid(); |
|
19 | |||
20 | 3 | $this->calls[$uniqid] = new OutstandingCall($uniqid, $canceller, function (OutstandingCall $call) { |
|
21 | 1 | unset($this->calls[$call->getUniqid()]); |
|
22 | 3 | }); |
|
23 | |||
24 | 3 | return $this->calls[$uniqid]; |
|
25 | } |
||
26 | |||
57 |